Skip to content
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

[STABLE-2.2] dma-trace.c: lower log level of dropped logs and stop the recursion #9036

Merged
merged 1 commit into from
May 2, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 3 additions & 9 deletions src/trace/dma-trace.c
Original file line number Diff line number Diff line change
Expand Up @@ -645,15 +645,9 @@ static void dtrace_add_event(const char *e, uint32_t length)
uint32_t tmp_dropped_entries =
trace_data->dropped_entries;
trace_data->dropped_entries = 0;
/*
* this trace_error invocation causes recursion,
* so after it we have to recalculate margin and
* overflow
*/
tr_err(&dt_tr, "dtrace_add_event(): number of dropped logs = %u",
tmp_dropped_entries);
margin = dtrace_calc_buf_margin(buffer);
overflow = dtrace_calc_buf_overflow(buffer, length);
mtrace_printf(LOG_LEVEL_WARNING,
"dtrace_add_event(): number of dropped logs = %u",
tmp_dropped_entries);
}
}

Expand Down
Loading