Re: [PATCH] arm64: Fix garbled logs caused by race between multiple stack traces

From: David Sauerwein

Date: Thu May 07 2026 - 08:39:01 EST


On Wed, May 06, 2026 at 11:58:44AM +0100, Catalin Marinas wrote:
> While the above does solve the line splitting, the trace is still not
> that readable as we get line interleaving.
>
> I wonder whether we could do something like dump_stack_lvl() at the
> show_regs() level to synchronise the printing. If that works, we
> wouldn't need the above change (which isn't incorrect but maybe we can
> do better).

I think the change is still needed in either case. Other threads can log
something unrelated to the stack traces which can still cause the
register lines to be broken. After all, use of pr_cont is discouraged.
checkpatch.pl warns saying "Avoid logging continuation uses where
feasible" when adding new callers of pr_cont.

I agree though that forcing stack traces to be printed sequentially
would help with readability. Maybe this can be added as a separate
change.

Thanks,
David



Amazon Web Services Development Center Germany GmbH
Tamara-Danz-Str. 13
10243 Berlin
Geschaeftsfuehrung: Christof Hellmis, Andreas Stieger
Eingetragen am Amtsgericht Charlottenburg unter HRB 257764 B
Sitz: Berlin
Ust-ID: DE 365 538 597