010194dd96716c79c0128a20e407c427c83c6aa2
[openembedded.git] /
1 From d2888c7643b07687b14a839239cbe7fc5bf565e6 Mon Sep 17 00:00:00 2001
2 From: Mark Brown <broonie@opensource.wolfsonmicro.com>
3 Date: Mon, 14 Jan 2008 23:24:26 +0300
4 Subject: [PATCH 37/64] Don't lock the codec list in snd_soc_dapm_new_widgets()
5
6 snd_soc_dapm_new_widgets() takes the codec lock when adding new widgets,
7 causing lockdep warnings when applications later call down through ALSA
8 to adjust controls.  Since widgets are only added during probe this lock
9 should be unneeded so don't take it.
10
11 Thanks to Dmitry Baryshkov <dbaryshkov@gmail.com> for reporting this issue.
12
13 Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
14 Cc: Dmitry Baryshkov <dbaryshkov@gmail.com>
15 ---
16  sound/soc/soc-dapm.c |    2 --
17  1 files changed, 0 insertions(+), 2 deletions(-)
18
19 diff --git a/sound/soc/soc-dapm.c b/sound/soc/soc-dapm.c
20 index 29a546f..e46cdc5 100644
21 --- a/sound/soc/soc-dapm.c
22 +++ b/sound/soc/soc-dapm.c
23 @@ -963,7 +963,6 @@ int snd_soc_dapm_new_widgets(struct snd_soc_codec *codec)
24  {
25         struct snd_soc_dapm_widget *w;
26  
27 -       mutex_lock(&codec->mutex);
28         list_for_each_entry(w, &codec->dapm_widgets, list)
29         {
30                 if (w->new)
31 @@ -998,7 +997,6 @@ int snd_soc_dapm_new_widgets(struct snd_soc_codec *codec)
32         }
33  
34         dapm_power_widgets(codec, SND_SOC_DAPM_STREAM_NOP);
35 -       mutex_unlock(&codec->mutex);
36         return 0;
37  }
38  EXPORT_SYMBOL_GPL(snd_soc_dapm_new_widgets);
39 -- 
40 1.5.3.8
41