Re: snd_hda_intel/sst-acpi sound breakage on suspend/resume since 5.6-rc1

From: Cezary Rojewski
Date: Thu Mar 19 2020 - 13:41:42 EST


On 2020-03-19 18:21, Pierre-Louis Bossart wrote:
On 3/19/20 11:51 AM, Dominik Brodowski wrote:
On Thu, Mar 19, 2020 at 04:48:03PM +0100, Cezary Rojewski wrote:


Requested for tests with following diff applied:

diff --git a/sound/soc/intel/boards/broadwell.c
b/sound/soc/intel/boards/broadwell.c
index db7e1e87156d..6ed4c1b0a515 100644
--- a/sound/soc/intel/boards/broadwell.c
+++ b/sound/soc/intel/boards/broadwell.c
@@ -212,7 +212,6 @@ static struct snd_soc_dai_link broadwell_rt286_dais[] =
{
ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂ .init = broadwell_rt286_codec_init,
ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂ .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF |
ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂ SND_SOC_DAIFMT_CBS_CFS,
-ÂÂÂÂÂÂÂÂÂÂÂÂÂÂ .ignore_suspend = 1,
ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂ .ignore_pmdown_time = 1,
ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂ .be_hw_params_fixup = broadwell_ssp0_fixup,
ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂ .ops = &broadwell_rt286_ops,

That patch fixes the issue(s). I didn't even need to revert 64df6afa0dab
("ASoC: Intel: broadwell: change cpu_dai and platform components for SOF")
on top of that. But you can assess better whether that patch needs care for
other reasons; for me, this one-liner you have suggested is perfect.

.ignore_suspend is set for bdw-rt5677.c and bdw-rt5650.c as well. I don't know if that was intentional.

haswell has it too.

My guess is that it's supposed to mimic offload behaviour on Windows: offload pin playback allows for non-interrupted playback during sleep while system pin follows standard path: breaks on sleep and resumes once sleep concludes. This of course also involves cooperation from application side.

However, one pin cannot serve two masters. Either it's offload or it's not.

This is just a guess of course, and my vision might be clouded becuase of Windows background.
Other SSP0 examples: rt286 (SKL/ KBL) rt298 (APL) and rt274 (CNL) do not have .ignore_suspend enabled for their links, except when DMIC is involved. So it might be just a bug that has been covered by another bug present in ASoC core, which Morimoto' San fixed during his cleanup series.

Czarek