Skip to contentSkip to conversation

riscv: use KERN_INFO in do_trap

PATCH Applied Andreas Schwab 5 participants 6 messages Mar 19, 2024 – Apr 4, 2024 RISC-V

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 riscv: use KERN_INFO in do_trap

Print the instruction dump with info instead of emergency level. The unhandled signal message is only for informational purpose.

Fixes b8a03a634129 ("riscv: add userland instruction dump to RISC-V splats")

---
v2: clarify commit message

---
 arch/riscv/kernel/traps.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/riscv/kernel/traps.c +1 -1
index a1b9be3c4332..142f5f5168fb 100644
@@ -121,7 +121,7 @@ void do_trap(struct pt_regs *regs, int signo, int code, unsigned long addr)
 		print_vma_addr(KERN_CONT " in ", instruction_pointer(regs));
 		pr_cont("\n");
 		__show_regs(regs);
-		dump_instr(KERN_EMERG, regs);
+		dump_instr(KERN_INFO, regs);
 	}
 
 	force_sig_fault(signo, code, (void __user *)addr);
Signature · 7 lines
2.44.0


-- 
Andreas Schwab, SUSE Labs, [email protected]
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE  1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."
Reviewed-by on v2 1/1
#1 lore raw
Quoted 17 lines · Andreas Schwab

Print the instruction dump with info instead of emergency level. The unhandled signal message is only for informational purpose.

Fixes b8a03a634129 ("riscv: add userland instruction dump to RISC-V splats")

---
v2: clarify commit message

---
  arch/riscv/kernel/traps.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
arch/riscv/kernel/traps.c +0 -0
index a1b9be3c4332..142f5f5168fb 100644

arch/riscv/kernel/traps.c void do_trap(struct pt_regs *regs, int signo, int code, unsigned long addr) · line 127

Quoted 8 lines
arch/riscv/kernel/traps.c +1 -1
@@ -121,7 +121,7 @@ void do_trap(struct pt_regs *regs, int signo, int code, unsigned long addr)
  		print_vma_addr(KERN_CONT " in ", instruction_pointer(regs));
  		pr_cont("\n");
  		__show_regs(regs);
-		dump_instr(KERN_EMERG, regs);
+		dump_instr(KERN_INFO, regs);
  	}
 
  	force_sig_fault(signo, code, (void __user *)addr);
Reviewed-by on v2 1/1
#2 lore raw
In reply to Andreas Schwab

Hi Andreas,

Quoted 30 lines · Andreas Schwab

Print the instruction dump with info instead of emergency level. The unhandled signal message is only for informational purpose.

Fixes b8a03a634129 ("riscv: add userland instruction dump to RISC-V splats")

---
v2: clarify commit message

---
 arch/riscv/kernel/traps.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/riscv/kernel/traps.c +1 -2
index a1b9be3c4332..142f5f5168fb 100644
@@ -121,7 +121,7 @@ void do_trap(struct pt_regs *regs, int signo, int code, unsigned long addr)
                print_vma_addr(KERN_CONT " in ", instruction_pointer(regs));
                pr_cont("\n");
                __show_regs(regs);
-               dump_instr(KERN_EMERG, regs);
+               dump_instr(KERN_INFO, regs);
        }
 
        force_sig_fault(signo, code, (void __user *)addr);
--

2.44.0

Quoted 4 lines

--
Andreas Schwab, SUSE Labs, [email protected]
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7 "And now for something completely different."

Thanks,
Yunhui

maintainer
#4 lore raw
Quoted 1 line · On Thu, 04 Apr 2024 06:41:46 PDT (-0700), [email protected] wrote:

Ping!

Sorry I missed this, I just put it in the queue for the tester. Unless something blows up it should show up soon.

#5 lore raw
In reply to Andreas Schwab
This patch was applied to riscv/linux.git (fixes) by Palmer Dabbelt <[email protected]>:

Hello:

This patch was applied to riscv/linux.git (fixes)
by Palmer Dabbelt <[email protected]>:

Quoted 8 lines · On Tue, 19 Mar 2024 16:40:05 +0100 you wrote:

Print the instruction dump with info instead of emergency level. The unhandled signal message is only for informational purpose.

Fixes b8a03a634129 ("riscv: add userland instruction dump to RISC-V splats")

[...]

Here is the summary with links:
- [v2] riscv: use KERN_INFO in do_trap

    https://git.kernel.org/riscv/c/dd33e5dc7247

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html