linux/sound/soc
Ranjani Sridharan 8e84b6a4e7
ASoC: SOF: remove incorrect clearing of prepared flag
When the system is suspended while a PCM is paused, it doesn't receive
the SUSPEND trigger. So, the SOF driver has to ensure that the PCM and
the widgets associated with the paused PCM are freed in the firmware
during suspend. This is handled in the
sof_tear_down_left_over_pipelines() call. But since the state of this
PCM is SUSPENDED, we end up clearing the prepared flag for the PCM
before freeing it. This results in IPC errors while freeing the widgets.
But because the widget use_counts are reset to 0 even though the IPC
fails, releasing the paused stream after resuming from suspend proceeds
normally.

Fix the IPC errors by removing the clearing of the prepared flag in
sof_set_hw_params_upon_resume(). In fact, we can remove the
sof_set_hw_params_upon_resume() and call
snd_sof_dsp_hw_params_upon_resume() directly. This will ensure that the
PCM is freed in the firmware before the IPC's for freeing the widgets
are sent.

BugLink: https://github.com/thesofproject/linux/issues/3543
Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com>
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20220421203201.1550328-2-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
2022-04-25 13:58:24 +01:00
..
adi
amd ASoC: amd: acp: Add pm ops callback in machine driver 2022-04-20 14:25:13 +01:00
atmel ASoC: wm8731: Overhaul of the driver 2022-04-05 10:25:00 +01:00
au1x ASoC: wm8731: Factor out the I2C and SPI bus code into separate modules 2022-04-04 08:39:32 +01:00
bcm ASoC: bcm: Use platform_get_irq() to get the interrupt 2021-12-21 18:05:43 +00:00
cirrus ARM: SoC drivers for 5.16 2021-11-03 17:00:52 -07:00
codecs ASoC: max98390: Add reset gpio control 2022-04-21 15:52:56 +01:00
dwc ASoC: dwc-i2s: Handle errors for clk_enable 2022-03-02 13:45:24 +00:00
fsl ASoC: fsl_micfil: Driver updates 2022-04-20 14:22:03 +01:00
generic ASoC: audio-graph-card2: indicate "Experimental stage" warning only when successed 2022-04-21 15:53:14 +01:00
hisilicon
img ASoC: img: Use dev_err_probe() helper 2021-12-20 12:47:16 +00:00
intel ASoC: Intel: sof_ssp_amp: remove 'set-but-not-used' warning 2022-04-21 18:25:20 +01:00
jz4740
kirkwood
mediatek ASoC: soc-card: Create jack kcontrol without pins 2022-04-14 17:37:21 +01:00
meson ASoC: meson: aiu: fix duplicate debugfs directory error 2022-04-05 19:14:21 +01:00
mxs ASoC: mxs: Fix error handling in mxs_sgtl5000_probe 2022-03-08 13:41:15 +00:00
pxa ASoC: soc-card: Create jack kcontrol without pins 2022-04-14 17:37:21 +01:00
qcom ASoC: qcom: lpass-platform: Update memremap flag to MEMREMAP_WC 2022-04-19 12:04:07 +01:00
rockchip ASoC: soc-card: Create jack kcontrol without pins 2022-04-14 17:37:21 +01:00
samsung ASoC: soc-card: Create jack kcontrol without pins 2022-04-14 17:37:21 +01:00
sh ASoC: rsnd: care return value from rsnd_node_fixed_index() 2022-04-21 15:53:15 +01:00
sof ASoC: SOF: remove incorrect clearing of prepared flag 2022-04-25 13:58:24 +01:00
spear
sprd
sti ASoC: sti: Fix deadlock via snd_pcm_stop_xrun() call 2022-03-16 16:39:28 +00:00
stm ASoC: stm: Use dev_err_probe() helper 2021-12-20 12:47:23 +00:00
sunxi ASoC: sun4i-i2s: Add support for the R329/D1 variant 2022-02-03 11:30:57 +00:00
tegra ASoC: soc-card: Create jack kcontrol without pins 2022-04-14 17:37:21 +01:00
ti ASoC: soc-card: Create jack kcontrol without pins 2022-04-14 17:37:21 +01:00
uniphier ASoC: uniphier: drop selecting non-existing SND_SOC_UNIPHIER_AIO_DMA 2021-11-25 11:54:30 +00:00
ux500
xilinx ASoC: xilinx: xlnx_i2s: Handle sysclk setting 2022-01-24 19:45:38 +00:00
xtensa
Kconfig ASoC: soc-utils: Add kunit test for snd_soc_tdm_params_to_bclk() 2022-04-05 18:27:56 +01:00
Makefile ASoC: soc-utils: Add kunit test for snd_soc_tdm_params_to_bclk() 2022-04-05 18:27:56 +01:00
soc-ac97.c
soc-acpi.c ALSA: Replace acpi_bus_get_device() 2022-02-01 08:08:08 +01:00
soc-card.c ASoC: soc-card: Create jack kcontrol without pins 2022-04-14 17:37:21 +01:00
soc-component.c ASoC: soc-component: add snd_soc_pcm_component_delay() 2021-11-29 12:19:41 +00:00
soc-compress.c ASoC: soc-compress: Change the check for codec_dai 2022-03-14 08:29:11 +00:00
soc-core.c ASoC: soc-core: remove always-false path 2022-04-23 00:16:28 +01:00
soc-dai.c ASoC: soc-dai: update snd_soc_dai_delay() to snd_soc_pcm_dai_delay() 2021-11-29 12:19:40 +00:00
soc-dapm.c ASoC: soc-dapm: fix two incorrect uses of list iterator 2022-04-05 10:24:44 +01:00
soc-devres.c
soc-generic-dmaengine-pcm.c ASoC: dmaengine: do not use a NULL prepare_slave_config() callback 2022-03-08 13:38:56 +00:00
soc-jack.c ASoC: soc-card: Create jack kcontrol without pins 2022-04-14 17:37:21 +01:00
soc-link.c
soc-ops.c ASoC: ops: Shift tested values in snd_soc_put_volsw() by +min 2022-02-16 16:33:48 +00:00
soc-pcm.c ASoC: soc-pcm: improve BE transition for TRIGGER_START 2022-04-19 16:33:52 +01:00
soc-topology-test.c
soc-topology.c ASoC: Pull in fixes 2022-04-05 10:29:12 +01:00
soc-utils-test.c ASoC: soc-utils: Add kunit test for snd_soc_tdm_params_to_bclk() 2022-04-05 18:27:56 +01:00
soc-utils.c ASoC: soc-utils: Add helper to calculate BCLK from TDM info 2022-04-05 18:27:55 +01:00