summaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs/ak4613.c
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2022-04-05 04:06:08 +0200
committerMark Brown <broonie@kernel.org>2022-04-05 19:49:55 +0200
commit3407e36dc78f4a980588c9347076aee9925ca51f (patch)
tree47b4903ed97ea3dce7d9a577895d802a6b9798b8 /sound/soc/codecs/ak4613.c
parentLinux 5.18-rc1 (diff)
downloadlinux-3407e36dc78f4a980588c9347076aee9925ca51f.tar.xz
linux-3407e36dc78f4a980588c9347076aee9925ca51f.zip
ASoC: ak4613: add missing mutex_lock()
We need to use mutex_lock() for priv->cnt / priv->iface, but we are missing it at ak4613_dai_startup(). This patch adds missing mutex_lock() for it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://lore.kernel.org/r/87fsmsp9m7.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/codecs/ak4613.c')
-rw-r--r--sound/soc/codecs/ak4613.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/soc/codecs/ak4613.c b/sound/soc/codecs/ak4613.c
index 034195c83bd7..e0d9a8c58e10 100644
--- a/sound/soc/codecs/ak4613.c
+++ b/sound/soc/codecs/ak4613.c
@@ -304,7 +304,9 @@ static int ak4613_dai_startup(struct snd_pcm_substream *substream,
struct snd_soc_component *component = dai->component;
struct ak4613_priv *priv = snd_soc_component_get_drvdata(component);
+ mutex_lock(&priv->lock);
priv->cnt++;
+ mutex_unlock(&priv->lock);
ak4613_hw_constraints(priv, substream->runtime);