diff options
| author | Sebastien Jan <s-jan@ti.com> | 2011-05-31 09:23:13 +0100 |
|---|---|---|
| committer | Andy Green <andy.green@linaro.org> | 2011-05-31 11:04:43 +0100 |
| commit | e92d2a02493c18802070ce600a3943caae0ec4da (patch) | |
| tree | b06165f3d75a90b7cb9a4f2c8182042be5868f0b /sound | |
| parent | b2b8ffa1159c54d3f933b31e9e2bd92d2b4599a0 (diff) | |
ASoC: Fix DAPM codec init
For OMAP4, a widget is used without a codec associated,
so accessing the codec would generate a hang.
This may be a temporary hack. Final solution is discussed
upstream.
Signed-off-by: Sebastien Jan <s-jan@ti.com>
Signed-off-by: Sebastien Guiriec <s-guiriec@ti.com>
Diffstat (limited to 'sound')
| -rw-r--r-- | sound/soc/soc-dapm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/soc-dapm.c b/sound/soc/soc-dapm.c index f5e2e6b4eca..4f69ef40f07 100644 --- a/sound/soc/soc-dapm.c +++ b/sound/soc/soc-dapm.c @@ -1961,7 +1961,7 @@ int snd_soc_dapm_new_widgets(struct snd_soc_dapm_context *dapm) } /* Read the initial power state from the device */ - if (w->reg >= 0) { + if (w->reg >= 0 && w->codec) { val = snd_soc_read(w->codec, w->reg); val &= 1 << w->shift; if (w->invert) |
