ASoC: SOF: Intel: hda: Compensate LLP in case it is not reset
authorPeter Ujfalusi <peter.ujfalusi@linux.intel.com>
Thu, 21 Mar 2024 13:08:14 +0000 (15:08 +0200)
committerMark Brown <broonie@kernel.org>
Mon, 25 Mar 2024 16:36:06 +0000 (16:36 +0000)
commit1abc2642588e06f6180b3fbb21968cf5d0ba9e5f
treef30f3d6e173c7a132522fbfcee6242c9db7326af
parentf9eeb6bb13fb5d7af1ea5b74a10b1f8ead962540
ASoC: SOF: Intel: hda: Compensate LLP in case it is not reset

During pause/reset or stop/start the LLP counter is not reset, which will
result broken delay reporting.

Read the LLP value on STOP/PAUSE trigger and use it in LLP reading to
normalize the LLP from the register.

Cc: stable@vger.kernel.org # 6.8
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://msgid.link/r/20240321130814.4412-18-peter.ujfalusi@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sof/intel/hda-dai-ops.c
sound/soc/sof/intel/hda-pcm.c
sound/soc/sof/intel/hda-stream.c