Skip to content

ASoC: SOF: ipc3-dtrace: Handle race during initialization

Peter Ujfalusi alsa-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3ASoC: SOF: ipc3-dtrace: Introduce SOF_DTRACE_INITIALIZING statesound/soc/sof/ipc3-dtrace.c+16 -40 replies
2/3ASoC: SOF: ipc3-dtrace: Add helper function to update the sdev->host_offsetsound/soc/sof/ipc3-dtrace.c+18 -50 replies
3/3ASoC: SOF: ipc3-dtrace: Return from dtrace_read if there is no new data availablesound/soc/sof/ipc3-dtrace.c+4 -00 replies

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchPierre-Louis BossartBard Liao
1/3R-b R-b
2/3R-b R-b
3/3R-b R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/3] ASoC: SOF: ipc3-dtrace: Handle race during initialization

Hi,

This series handles the race which can result missing the first position update after the trace is enabled.
In short: the firmware might send the position update (if we have enough trace data generated) after the dma-trace is enabled by the TRACE_DMA_PARAMS_EXT message. Depending on scheduling, load, preemption on Linux side we have seen that occasionally this first position update got missed and we missed reading it out.

A new state and more strict handling of host_offset can overcome this issue, making the dtrace more reliable.

Regards,
Peter
---
Peter Ujfalusi (3):
ASoC: SOF: ipc3-dtrace: Introduce SOF_DTRACE_INITIALIZING state
ASoC: SOF: ipc3-dtrace: Add helper function to update the

    sdev->host_offset

ASoC: SOF: ipc3-dtrace: Return from dtrace_read if there is no new
data available

 sound/soc/sof/ipc3-dtrace.c | 47 ++++++++++++++++++++++++++++++-------
 1 file changed, 38 insertions(+), 9 deletions(-)
Signature · 1 line
2.36.1