-
Notifications
You must be signed in to change notification settings - Fork 349
trace: Add SOF_IPC_TRACE_DMA_FREE IPC command #4849
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
7d4a946 to
28b0dd2
Compare
src/trace/dma-trace.c
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we also put the channel and set d->dc.chan to NULL?
SOF_IPC_TRACE_DMA_PARAMS_EXT will fail if we have a valid channel already.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unless we also have #4850 along with this patch.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would still put the channel for consistency:
if (d->dc.chan) {
dma_stop(d->dc.chan); /* Should we do an error check? */
dma_channel_put(d->dc.chan);
d->dc.chan = NULL;
}There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, ill release the channel but error checking would be pointless because trace work is already stopped right?
src/trace/dma-trace.c
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgirdwood
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ujfalusi pls approve if good for you.
|
@ranj063 looks like we have a crash |
src/ipc/ipc3/handler.c
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why don't we call this as dma_trace_free() to be consistent?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it balances with trace_dma_enable during ipc_dma_trace_params() no?
src/trace/dma-trace.c
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would still put the channel for consistency:
if (d->dc.chan) {
dma_stop(d->dc.chan); /* Should we do an error check? */
dma_channel_put(d->dc.chan);
d->dc.chan = NULL;
}This will be used to stop the trace DMA and free its resources. This change is tagged for ABI 3.20. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
28b0dd2 to
390b0d1
Compare
ujfalusi
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ranj063, thank you, looks great!
|
CI showing a presence detect failure on ADL. @marc-hb I've seen this several time today, looks like we may need to filter the cpufreq errors out ? https://sof-ci.01.org/sofpr/PR4849/build10723/devicetest/?model=ADLP_RVP_SDW&testcase=verify-kernel-boot-log |
|
cpufreq - and more. All boot logs on ADK: thesofproject/sof-test#786 |
This will be used to stop the trace DMA and free
its resources. This change is tagged for ABI 3.20.
kernel PR thesofproject/linux#3197