diff options
author | Liam Girdwood <lrg@ti.com> | 2012-03-07 10:38:26 +0000 |
---|---|---|
committer | Mrutyunjay Sawant <msawant@nvidia.com> | 2012-09-04 05:16:10 -0700 |
commit | bad016421fc94642de2ad70a78d2917549d81541 (patch) | |
tree | a1519985b73c334f591a7e0393eda1fc35d76f01 /include | |
parent | 616ade39df296b2c60d8ce74c719bc560f78f598 (diff) |
ASoC: dapm: Use DAPM mutex for DAPM ops instead of codec mutex
It has now become necessary to use a DAPM mutex instead of the codec
mutex to lock the DAPM operations. This is due to the recent multi
component support and forth coming Dynamic PCM updates.
Currently we lock DAPM operations with the codec mutex of the calling
RTD context. However, DAPM operations can span the whole card context
and all components.
This patch updates the DAPM operations that use the codec mutex to
now use the DAPM mutex PCM subclass for all DAPM ops.
We also add a mutex subclass for DAPM init and PCM operations.
Signed-off-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
(cherry picked from commit a73fb2df01866b772a48fab93401fe3edbe0b38d)
Updated call sequences
Bug 1039523
Change-Id: If079bbe5032971251d6b5426c752cbcc6ad6bcf5
Signed-off-by: Sang-Hun Lee <sanlee@nvidia.com>
Reviewed-on: http://git-master/r/128937
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/sound/soc-dapm.h | 5 | ||||
-rw-r--r-- | include/sound/soc.h | 1 |
2 files changed, 6 insertions, 0 deletions
diff --git a/include/sound/soc-dapm.h b/include/sound/soc-dapm.h index e0583b7769cb..3bfd6e58b60c 100644 --- a/include/sound/soc-dapm.h +++ b/include/sound/soc-dapm.h @@ -408,6 +408,11 @@ enum snd_soc_dapm_type { snd_soc_dapm_aif_out, /* audio interface output */ }; +enum snd_soc_dapm_subclass { + SND_SOC_DAPM_CLASS_INIT = 0, + SND_SOC_DAPM_CLASS_PCM = 1, +}; + /* * DAPM audio route definition. * diff --git a/include/sound/soc.h b/include/sound/soc.h index aa19f5a32ba8..878807c0c283 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -751,6 +751,7 @@ struct snd_soc_card { struct list_head list; struct mutex mutex; + struct mutex dapm_mutex; bool instantiated; |