diff options
author | Lars-Peter Clausen <lars@metafoo.de> | 2015-01-15 12:52:17 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2015-01-15 12:57:34 +0100 |
commit | 96da4e5b2e1d04478fb6d540085f2859256ca788 (patch) | |
tree | 185d96142da2d784c8e688130640dcaff88e99b4 /sound/soc/soc-dapm.c | |
parent | ASoC: rt5677: Replace w->codec snd_soc_dapm_to_codec(w->dapm) (diff) | |
download | linux-96da4e5b2e1d04478fb6d540085f2859256ca788.tar.xz linux-96da4e5b2e1d04478fb6d540085f2859256ca788.zip |
ASoC: Remove codec field from snd_soc_dapm_widget
There are no more users of this field left so it can finally be removed.
New users should use snd_soc_dapm_to_codec(w->dapm);
The reason why it is removed is because it doesn't fit to well anymore in
the componentized ASoC hierarchy, where DAPM works on the snd_soc_component
level. And the alternative of snd_soc_dapm_to_codec(w->dapm) typically
generates the same amount of code, so there is really no reason to keep it.
For automatic conversion the following coccinelle semantic patch can be used:
// <smpl>
@@
struct snd_soc_dapm_widget *w;
@@
-w->codec
+snd_soc_dapm_to_codec(w->dapm)
// </smpl>
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/soc-dapm.c')
-rw-r--r-- | sound/soc/soc-dapm.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/sound/soc/soc-dapm.c b/sound/soc/soc-dapm.c index c5136bb1f982..f6ae254e33ef 100644 --- a/sound/soc/soc-dapm.c +++ b/sound/soc/soc-dapm.c @@ -3130,8 +3130,6 @@ snd_soc_dapm_new_control(struct snd_soc_dapm_context *dapm, } w->dapm = dapm; - if (dapm->component) - w->codec = dapm->component->codec; INIT_LIST_HEAD(&w->sources); INIT_LIST_HEAD(&w->sinks); INIT_LIST_HEAD(&w->list); |