提交 a489ca35 编写于 作者: A Arjan van de Ven 提交者: Ingo Molnar

x86: Make sure we also print a Code: line for show_regs()

show_regs() is called as a mini BUG() equivalent in some places,
specifically for the "scheduling while atomic" case.

Unfortunately right now it does not print a Code: line unlike
a real bug/oops.

This patch changes the x86 implementation of show_regs() so that
it calls the same function as oopses do to print the registers
as well as the Code: line.
Signed-off-by: NArjan van de Ven <arjan@linux.intel.com>
LKML-Reference: <20091102165915.4a980fc0@infradead.org>
Signed-off-by: NIngo Molnar <mingo@elte.hu>
上级 1836d959
......@@ -187,7 +187,7 @@ void __show_regs(struct pt_regs *regs, int all)
void show_regs(struct pt_regs *regs)
{
__show_regs(regs, 1);
show_registers(regs);
show_trace(NULL, regs, &regs->sp, regs->bp);
}
......
......@@ -226,8 +226,7 @@ void __show_regs(struct pt_regs *regs, int all)
void show_regs(struct pt_regs *regs)
{
printk(KERN_INFO "CPU %d:", smp_processor_id());
__show_regs(regs, 1);
show_registers(regs);
show_trace(NULL, regs, (void *)(regs + 1), regs->bp);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册