diff options
author | Rander Wang <rander.wang@intel.com> | 2023-02-02 14:29:54 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2023-02-03 13:03:55 +0100 |
commit | 3937a76c64931109dfafa999a0c78b4df2a6e0a1 (patch) | |
tree | 7c26b451bfd63cefb2319c8d8cb08b6371fa0127 /sound/soc/sof/ipc4-topology.h | |
parent | ASoC: SOF: Intel: mtl: add get_stream_position support (diff) | |
download | linux-3937a76c64931109dfafa999a0c78b4df2a6e0a1.tar.xz linux-3937a76c64931109dfafa999a0c78b4df2a6e0a1.zip |
ASoC: SOF: ipc4-pcm: add delay function support
The delay function is used to calculate the difference
between hw_ptr and dai dma position. I2S, DMIC and SDW will
use dai dma position in shared SRAM window to calculate the
delay. HDaudio will retrieve dai dma position from host mmio memory
space since it doesn't support LLP counter reported by firmware.
In two cases dai dma position is inaccurate for delay calculation
(1) dai pipeline is started before host pipeline
(2) multiple streams mixed into one. Each stream has the same dai
dma position
Firmware calculates correct stream_start_offset for all cases including
above two. Driver subtracts stream_start_offset from dai dma position to
get accurate one.
Signed-off-by: Rander Wang <rander.wang@intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Ranjani Sridharan <ranjani.sridharan@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://lore.kernel.org/r/20230202132954.26773-10-peter.ujfalusi@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/sof/ipc4-topology.h')
0 files changed, 0 insertions, 0 deletions