]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
ASoC: SOF: ipc4-pcm: do not report invalid delay values
authorKai Vehmanen <kai.vehmanen@linux.intel.com>
Thu, 2 Oct 2025 07:47:18 +0000 (10:47 +0300)
committerMark Brown <broonie@kernel.org>
Fri, 3 Oct 2025 11:39:48 +0000 (12:39 +0100)
commita4b8152c09a832b089864e5e209a479bb0fb5cc9
tree55e5a28740b09e24331f7cf4cd2c2e02c7a4d9e9
parent18dbff48a1ea58100f9fa6886cfef286a96a5fb0
ASoC: SOF: ipc4-pcm: do not report invalid delay values

Add a sanity check for the calculated delay value before reporting it to
the application. If the value is clearly invalid, emit a rate limited
warning to kernel log and return a zero delay. This can occur e.g if the
host or link DMA hits a buffer over/underrun condition.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com>
Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Link: https://patch.msgid.link/20251002074719.2084-5-peter.ujfalusi@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sof/ipc4-pcm.c