提交 cc22d37e 编写于 作者: L Liam Girdwood 提交者: Mark Brown

ASoC: core: Add platform component mutex

Add mutex support for platform IO operations. e.g. can be used
for platform DAPM widget IO ops.
Signed-off-by: NLiam Girdwood <lrg@ti.com>
Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
上级 c25cd154
......@@ -718,6 +718,7 @@ struct snd_soc_platform {
int id;
struct device *dev;
struct snd_soc_platform_driver *driver;
struct mutex mutex;
unsigned int suspended:1; /* platform is suspended */
unsigned int probed:1;
......
......@@ -3382,6 +3382,7 @@ int snd_soc_register_platform(struct device *dev,
platform->dapm.dev = dev;
platform->dapm.platform = platform;
platform->dapm.stream_event = platform_drv->stream_event;
mutex_init(&platform->mutex);
mutex_lock(&client_mutex);
list_add(&platform->list, &platform_list);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册