OSDN Git Service

ASoC: SOF: add support for dynamic pipelines with multi-core
authorRanjani Sridharan <ranjani.sridharan@linux.intel.com>
Fri, 19 Nov 2021 19:26:20 +0000 (21:26 +0200)
committerMark Brown <broonie@kernel.org>
Mon, 22 Nov 2021 15:40:23 +0000 (15:40 +0000)
commit9ea807488cdaef83da702d4a02d54138b88f4377
tree7f46be49a784dae7ccf8f5122cf806e368778697
parentd416519982cb1d25358f558a4e68d9d254c9ca53
ASoC: SOF: add support for dynamic pipelines with multi-core

This patch adds support for dynamic pipelines with multi-core
by using the platform-specific core_get/put() ops to
power up/down a core when a widget is set up/freed.

Along with this, a few redundant functions are removed:
1. sof_pipeline_core_enable() is no longer needed as the
pipeline core will be set up when the pipeline widget
is set up
2. sof_core_enable() is replaced with snd_sof_core_get()
4. core_power_up/down() DSP ops are deprecated and replaced with
core get/put ops.
5. Core power down in sof_widget_unload() during topology
removal is also removed as it is not really needed. For dynamic
pipelines, the cores will be powered off when they are not used.
For static pipelines, the cores will be powered off in the device
remove callback.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Link: https://lore.kernel.org/r/20211119192621.4096077-10-kai.vehmanen@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sof/intel/apl.c
sound/soc/sof/intel/cnl.c
sound/soc/sof/intel/icl.c
sound/soc/sof/intel/tgl.c
sound/soc/sof/ops.h
sound/soc/sof/sof-audio.c
sound/soc/sof/sof-audio.h
sound/soc/sof/sof-priv.h
sound/soc/sof/topology.c