From: Axel Lin Date: Mon, 6 Dec 2010 08:48:03 +0000 (+0800) Subject: ASoC: Hold client_mutex while calling snd_soc_instantiate_cards() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=1dcb4f38e5bc28dfce0f8c7eef184a090b03bfc7;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git ASoC: Hold client_mutex while calling snd_soc_instantiate_cards() As the comments of snd_soc_instantiate_cards() said, snd_soc_instantiate_cards() must be called with client_mutex. Signed-off-by: Axel Lin Signed-off-by: Mark Brown --- diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index 441285ade024..02ae7bea3b50 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -3072,7 +3072,9 @@ int snd_soc_register_dais(struct device *dev, pr_debug("Registered DAI '%s'\n", dai->name); } + mutex_lock(&client_mutex); snd_soc_instantiate_cards(); + mutex_unlock(&client_mutex); return 0; err: