From 9e15ef80af4d34f8babb099f9247d7ec566d9dd9 Mon Sep 17 00:00:00 2001 From: Rander Wang Date: Fri, 18 Mar 2022 16:59:41 +0800 Subject: [PATCH] ipc4: dai: update wallclock for position update The original code was copied from ipc3 path but the wallclock usage is different. In ipc4 path fw needs update it for each position update. Signed-off-by: Rander Wang --- src/ipc/ipc4/dai.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/ipc/ipc4/dai.c b/src/ipc/ipc4/dai.c index 605371776..962606381 100644 --- a/src/ipc/ipc4/dai.c +++ b/src/ipc/ipc4/dai.c @@ -295,7 +295,7 @@ int dai_position(struct comp_dev *dev, struct sof_ipc_stream_posn *posn) /* total processed bytes count */ posn->dai_posn = dev->position; - /* set stream start wallclock */ + platform_dai_wallclock(dev, &dd->wallclock); posn->wallclock = dd->wallclock; status.ipc_posn_data = &posn->comp_posn; @@ -320,6 +320,8 @@ void dai_dma_position_update(struct comp_dev *dev) status.ipc_posn_data = llp_data; dma_status(dd->chan, &status, dev->direction); + platform_dai_wallclock(dev, &dd->wallclock); + slot.node_id = node_id; slot.reading.llp_l = llp_data[0]; slot.reading.llp_u = llp_data[1];