diff options
Diffstat (limited to 'arch/powerpc/kernel/process.c')
-rw-r--r-- | arch/powerpc/kernel/process.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/arch/powerpc/kernel/process.c b/arch/powerpc/kernel/process.c index f698aa77127e..995b14688d3a 100644 --- a/arch/powerpc/kernel/process.c +++ b/arch/powerpc/kernel/process.c | |||
@@ -362,7 +362,11 @@ static void show_instructions(struct pt_regs *regs) | |||
362 | if (!(i % 8)) | 362 | if (!(i % 8)) |
363 | printk("\n"); | 363 | printk("\n"); |
364 | 364 | ||
365 | if (BAD_PC(pc) || __get_user(instr, (unsigned int *)pc)) { | 365 | /* We use __get_user here *only* to avoid an OOPS on a |
366 | * bad address because the pc *should* only be a | ||
367 | * kernel address. | ||
368 | */ | ||
369 | if (BAD_PC(pc) || __get_user(instr, (unsigned int __user *)pc)) { | ||
366 | printk("XXXXXXXX "); | 370 | printk("XXXXXXXX "); |
367 | } else { | 371 | } else { |
368 | if (regs->nip == pc) | 372 | if (regs->nip == pc) |