summaryrefslogtreecommitdiffstats
path: root/sound/soc/sof/ipc4.c
diff options
context:
space:
mode:
authorRanjani Sridharan <ranjani.sridharan@linux.intel.com>2023-01-27 14:00:28 +0200
committerMark Brown <broonie@kernel.org>2023-01-27 12:14:11 +0000
commit6bc4d1b714aafc0ee3c7649c36aa19998b4c11f9 (patch)
tree76a8fcb50ac732333ac9d78362312a4ec8687293 /sound/soc/sof/ipc4.c
parent32c4b69872e5fe5fd9517826be31dbf2c3dd917a (diff)
downloadlinux-stable-6bc4d1b714aafc0ee3c7649c36aa19998b4c11f9.tar.gz
linux-stable-6bc4d1b714aafc0ee3c7649c36aa19998b4c11f9.tar.bz2
linux-stable-6bc4d1b714aafc0ee3c7649c36aa19998b4c11f9.zip
ASoC: SOF: ipc4-topology: Protect pipeline free with mutex
When starting/stopping multiple streams in parallel, pipeline triggers and pipeline frees can get interleaved. So use the same mutex used for pipeline trigger to protect the pipeline frees as well. Rename the trigger_mutex to pipeline_state_mutex for more clarity. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Link: https://lore.kernel.org/r/20230127120031.10709-16-peter.ujfalusi@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/sof/ipc4.c')
-rw-r--r--sound/soc/sof/ipc4.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/sof/ipc4.c b/sound/soc/sof/ipc4.c
index fb4760ae593f..35c9f3913d9a 100644
--- a/sound/soc/sof/ipc4.c
+++ b/sound/soc/sof/ipc4.c
@@ -662,7 +662,7 @@ static int sof_ipc4_init(struct snd_sof_dev *sdev)
{
struct sof_ipc4_fw_data *ipc4_data = sdev->private;
- mutex_init(&ipc4_data->trigger_mutex);
+ mutex_init(&ipc4_data->pipeline_state_mutex);
xa_init_flags(&ipc4_data->fw_lib_xa, XA_FLAGS_ALLOC);