Let us die more gracefully
PATCH 1/1 Let us die more gracefully
This patch dumps the offending code context rather than dumping the context of do_ri() function call itself.
Apply to both branches. (Same is true with the previous patch)
Jun
arch/mips/kernel/traps.c renamed from arch/mips/kernel/traps.c.orig +1 -2
@@ -614,8 +614,7 @@*/ asmlinkage void do_ri(struct pt_regs *regs) { -if (!user_mode (regs)) -BUG (); +die_if_kernel ("no ll/sc emulation for kernel code" , regs);#ifndef CONFIG_CPU_HAS_LLSC
Quoted 2 lines · Jun Sun
This patch dumps the offending code context rather than dumping the context of
do_ri()function call itself.
The message is misleading -- the reason may be any illegal opcode.
Signature · 3 lines
+ Maciej W. Rozycki, Technical University of Gdansk, Poland + +--------------------------------------------------------------+ + e-mail: [email protected], PGP key available +
Quoted 8 lines · Maciej W. Rozycki
Quoted 1 line · Jun Sun
This patch dumps the offending code context rather than dumping the context of
do_ri()function call itself.The message is misleading -- the reason may be any illegal opcode.
That is true. Here is the revised one.
Jun
arch/mips/kernel/traps.c renamed from arch/mips/kernel/traps.c.orig +1 -2
@@ -614,8 +614,7 @@*/ asmlinkage void do_ri(struct pt_regs *regs) { -if (!user_mode (regs)) -BUG (); +die_if_kernel ("Reserved instruction in kernel code" , regs);#ifndef CONFIG_CPU_HAS_LLSC