ARM 5977/1: Enable backtrace printing on oops when PC is corrupted

This commit is contained in:
Matt Sealey
2010-10-28 01:53:57 -05:00
parent bdcb202655
commit f82e55babe

View File

@@ -347,6 +347,9 @@ void unwind_backtrace(struct pt_regs *regs, struct task_struct *tsk)
frame.sp = regs->ARM_sp;
frame.lr = regs->ARM_lr;
frame.pc = regs->ARM_pc;
/* PC might be corrupted, use LR in that case. */
frame.pc = kernel_text_address(regs->ARM_pc)
? regs->ARM_pc : regs->ARM_lr;
} else if (tsk == current) {
frame.fp = (unsigned long)__builtin_frame_address(0);
frame.sp = current_sp;