linux/sound/soc/sof
Ranjani Sridharan 312ab447ba ASoC: SOF: ipc3-topology: Fix pipeline tear down logic
[ Upstream commit d7332c4a4f ]

With the change in the widget free logic to power down the cores only
when the scheduler widgets are freed, we need to ensure that the
scheduler widget is freed only after all the widgets associated with the
scheduler are freed. This is to ensure that the secondary core that the
scheduler is scheduled to run on is kept powered on until all widgets
that need them are in use. While this works well for dynamic pipelines,
in the case of static pipelines the current logic does not take this into
account and frees all widgets in the order they occur in the
widget_list. So, modify this to ensure that the scheduler widgets are freed
only after all other types of widgets in the widget_list are freed.

Link: https://github.com/thesofproject/linux/issues/4807
Fixes: 31ed8da1c8 ("ASoC: SOF: sof-audio: Modify logic for enabling/disabling topology cores")
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com>
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Link: https://lore.kernel.org/r/20240208133432.1688-1-peter.ujfalusi@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
History 2024-02-23 09:51:24 +01:00
..
amd ASoC: SOF: amd: add option to use sram for data bin loading 2023-10-23 13:29:56 +01:00
imx ASoC: SOF: make .remove callback return void 2023-10-12 20:28:12 +01:00
intel ASoC: SOF: Intel: pci-mtl: fix ARL-S definitions 2024-01-25 15:45:02 -08:00
mediatek ASoC: SOF: mediatek: mt8186: Revert Add Google Steelix topology compatible 2023-12-06 16:31:09 +00:00
xtensa ASoC: SOF: Xtensa: dump ar registers to restore call stack 2023-09-19 13:48:44 +01:00
compress.c ASoC: SOF: Use no_reply calls for TX 2023-04-20 12:51:45 +01:00
control.c ASoC: SOF: control: Extend the optionality of IPC ops to IPC as well 2022-12-25 23:32:33 +00:00
core.c ASoC: SOF: core: Add probe_early and remove_late callbacks 2023-10-19 14:53:50 +02:00
debug.c ASoC: SOF: debug: conditionally bump runtime_pm counter on exceptions 2023-05-15 10:20:57 +09:00
iomem-utils.c ASoC: SOF: Split up utils.c into sof-utils and iomem-utils 2022-02-10 15:19:04 +00:00
ipc.c ASoC: SOF: Use generic names for IPC types 2023-09-19 13:49:08 +01:00
ipc3-control.c ASoC: sof: Improve sof_ipc3_bytes_ext_put function 2023-05-23 19:31:14 +01:00
ipc3-dtrace.c ASoC: SOF: Use generic names for IPC types 2023-09-19 13:49:08 +01:00
ipc3-loader.c ASoC: SOF: Introduce container struct for SOF firmware 2022-10-21 13:04:54 +01:00
ipc3-pcm.c ASoC: sof: convert not to use asoc_xxx() 2023-09-26 17:18:42 +02:00
ipc3-priv.h ASoC: SOF: Refactor rx function for fuzzing 2023-06-09 10:44:39 +01:00
ipc3-topology.c ASoC: SOF: ipc3-topology: Fix pipeline tear down logic 2024-02-23 09:51:24 +01:00
ipc3.c ASoC: SOF: ipc3: Use devm_kmemdup to replace devm_kmalloc + memcpy 2023-08-14 19:44:39 +01:00
ipc4-control.c ASoC: SOF: ipc4-topology: Correct data structures for the GAIN module 2023-12-01 14:13:03 +00:00
ipc4-fw-reg.h ASoC: SOF: add ipc4_fw_reg header file 2023-02-03 12:03:48 +00:00
ipc4-loader.c ASoC: SOF: ipc4-loader: remove the CPC check warnings 2024-01-25 15:45:28 -08:00
ipc4-mtrace.c ASoC: SOF: ipc4-mtrace: move debug slot related definitions to header.h 2023-09-19 13:48:45 +01:00
ipc4-pcm.c ASoC: SOF: IPC4: sort pipeline based on priority 2023-10-06 12:30:23 +01:00
ipc4-priv.h ASoC: SOF: ipc4: add a helper function to search debug slot 2023-09-19 13:48:46 +01:00
ipc4-telemetry.c ASoC: SOF: ipc4: add definition of telemetry slot for exception handling 2023-09-19 13:48:47 +01:00
ipc4-telemetry.h ASoC: SOF: ipc4: add definition of telemetry slot for exception handling 2023-09-19 13:48:47 +01:00
ipc4-topology.c ASoC: SOF: ipc4-topology: Correct data structures for the GAIN module 2023-12-01 14:13:03 +00:00
ipc4-topology.h ASoC: SOF: ipc4-topology: Correct data structures for the GAIN module 2023-12-01 14:13:03 +00:00
ipc4.c ASoC: SOF: ipc4: Dump the notification payload 2023-10-12 20:28:11 +01:00
Kconfig ASoC: SOF: Kconfig: Rename SND_SOC_SOF_INTEL_IPC4 to SND_SOC_SOF_IPC4 2023-09-19 13:49:07 +01:00
loader.c ASoC: SOF: loader: Remove log prefixes for snd_sof_run_firmware 2023-03-07 13:58:16 +00:00
Makefile ASoC: SOF: ipc4/Intel: Support for firmware exception 2023-09-19 18:22:11 +01:00
nocodec.c ASoC: sof: convert not to use asoc_xxx() 2023-09-26 17:18:42 +02:00
ops.c ASoC: SOF: Switch to IPC generic firmware tracing 2022-05-19 16:44:15 +01:00
ops.h ASoC: SOF: Make return of remove_late void, too 2023-10-25 08:38:35 +02:00
pcm.c ASoC: sof: convert not to use asoc_xxx() 2023-09-26 17:18:42 +02:00
pm.c ASoC: SOF: pm: Remove duplicated code in sof_suspend 2023-06-16 12:53:53 +01:00
sof-acpi-dev.c ASoC: SOF: Convert to platform remove callback returning void 2023-10-10 19:21:04 +01:00
sof-acpi-dev.h ASoC: SOF: Convert to platform remove callback returning void 2023-10-10 19:21:04 +01:00
sof-audio.c ASoC: SOF: sof-audio: Modify logic for enabling/disabling topology cores 2023-11-24 14:15:06 +00:00
sof-audio.h ASoC: SOF: ipc4-topology: Add core_mask in struct snd_sof_pipeline 2023-11-24 14:15:06 +00:00
sof-client-ipc-flood-test.c ASoC: SOF: Use no_reply calls for TX 2023-04-20 12:51:45 +01:00
sof-client-ipc-kernel-injector.c ASoC: SOF: Add IPC3 Kernel Injector 2023-06-09 10:44:40 +01:00
sof-client-ipc-msg-injector.c ASoC: SOF: Use generic names for IPC types 2023-09-19 13:49:08 +01:00
sof-client-probes-ipc3.c ASoC: SOF: Use no_reply calls for TX 2023-04-20 12:51:45 +01:00
sof-client-probes-ipc4.c ASoC: SOF: sof-client-probes-ipc4: add checks to prevent static analysis warnings 2023-07-31 23:22:12 +01:00
sof-client-probes.c ASoC: SOF: Use generic names for IPC types 2023-09-19 13:49:08 +01:00
sof-client-probes.h ASoC: SOF: IPC4: probes: Implement IPC4 ops for probes client device 2022-10-31 13:20:22 +00:00
sof-client.c ASoC: SOF: sof-client: trivial: fix comment typo 2023-11-07 11:10:19 +00:00
sof-client.h ASoC: SOF: Add IPC3 Kernel Injector 2023-06-09 10:44:40 +01:00
sof-of-dev.c ASoC: SOF: Convert to platform remove callback returning void 2023-10-10 19:21:04 +01:00
sof-of-dev.h ASoC: SOF: Convert to platform remove callback returning void 2023-10-10 19:21:04 +01:00
sof-pci-dev.c ASoC: Merge up workaround for CODECs that play noise on stopped stream 2023-10-27 22:33:15 +01:00
sof-pci-dev.h ASoC: SOF: pci: split PCI into different drivers 2021-03-02 15:32:00 +01:00
sof-priv.h ASoC: SOF: Make return of remove_late void, too 2023-10-25 08:38:35 +02:00
sof-utils.c ASoC: SOF: remove unneeded dev_vdbg 2022-09-19 15:44:06 +01:00
sof-utils.h ASoC: SOF: Split up utils.c into sof-utils and iomem-utils 2022-02-10 15:19:04 +00:00
stream-ipc.c ASoC: SOF: Add support for compress API for stream data/offset 2023-01-17 13:37:53 +00:00
topology.c ASoC: SOF: topology: Use partial match for disconnecting DAI link and DAI widget 2024-01-25 15:45:01 -08:00
trace.c ASoC: SOF: trace: No need to check for op pointer in sof_fw_trace_free() 2022-12-25 23:32:39 +00:00