Skip to content

Commit

Permalink
[PATCH] x86_64: Resolve the RIP of an early exception using kallsyms
Browse files Browse the repository at this point in the history
But do it after everything else to risk less from recursive
crashes.

Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Andi Kleen authored and Linus Torvalds committed Feb 17, 2006
1 parent 7fd6784 commit 6574ffd
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions arch/x86_64/kernel/head.S
Original file line number Diff line number Diff line change
Expand Up @@ -213,13 +213,20 @@ ENTRY(early_idt_handler)
cmpl $2,early_recursion_flag(%rip)
jz 1f
call dump_stack
#ifdef CONFIG_KALLSYMS
leaq early_idt_ripmsg(%rip),%rdi
movq 8(%rsp),%rsi # get rip again
call __print_symbol
#endif
1: hlt
jmp 1b
early_recursion_flag:
.long 0

early_idt_msg:
.asciz "PANIC: early exception rip %lx error %lx cr2 %lx\n"
early_idt_ripmsg:
.asciz "RIP %s\n"

.code32
ENTRY(no_long_mode)
Expand Down

0 comments on commit 6574ffd

Please sign in to comment.