* [PATCH v1] RISC-V: Move the "Call Trace" to dump_backtrace()
@ 2022-04-19 17:48 Palmer Dabbelt
0 siblings, 0 replies; only message in thread
From: Palmer Dabbelt @ 2022-04-19 17:48 UTC (permalink / raw)
To: dvyukov, nogikh, syzkaller
Cc: Paul Walmsley, Palmer Dabbelt, aou, peterz, keescook, jszhang,
geert, chenhuang5, changbin.du, linux-riscv, linux-kernel,
Palmer Dabbelt
From: Palmer Dabbelt <palmer@rivosinc.com>
Our oopses include "Call Trace:", but in a different place than some
other targets do. This is breaking at least syzkaller, and likely other
bits of tooling that are trying to parse kernel stack traces.
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
---
I'm sort of just dead-reckoning this one based on the syzkaller issues
being reported in
<CACT4Y+ZA7CRNfYgPmi6jHTKD9rwvaJy=nh5Gz_c-PFHq3tuziQ@mail.gmail.com>, I
haven't tested this at all. There's a lot of other stuff here that
arm64 is doing, much of which seems like it could be pulled out into
generic code. I seem to remember having said that before, though...
I've left this as "Call Trace:" after seeing some patches to convert the
arm/ print from "Call trace:" to "Call Trace:". I can't find it again
and I remember it sounding like that wasn't necessary, but since we've
already got the capital I see no reason to change it. That looks to be
the more popular way.
Presumably this will break any tools parsing the current log format, but
given that we've changed it a handful of times and it looks like it's
just blowing up for folks as-is.
---
arch/riscv/kernel/stacktrace.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/riscv/kernel/stacktrace.c b/arch/riscv/kernel/stacktrace.c
index 08d11a53f39e..d5b91c0d1881 100644
--- a/arch/riscv/kernel/stacktrace.c
+++ b/arch/riscv/kernel/stacktrace.c
@@ -108,12 +108,12 @@ static bool print_trace_address(void *arg, unsigned long pc)
noinline void dump_backtrace(struct pt_regs *regs, struct task_struct *task,
const char *loglvl)
{
+ pr_cont("%sCall Trace:\n", loglvl);
walk_stackframe(task, regs, print_trace_address, (void *)loglvl);
}
void show_stack(struct task_struct *task, unsigned long *sp, const char *loglvl)
{
- pr_cont("%sCall Trace:\n", loglvl);
dump_backtrace(NULL, task, loglvl);
}
--
2.34.1
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-04-19 19:02 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-19 17:48 [PATCH v1] RISC-V: Move the "Call Trace" to dump_backtrace() Palmer Dabbelt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®