Loading arch/mips/kernel/branch.c +3 −2 Original line number Diff line number Diff line Loading @@ -22,7 +22,8 @@ */ int __compute_return_epc(struct pt_regs *regs) { unsigned int *addr, bit, fcr31, dspcontrol; unsigned int __user *addr; unsigned int bit, fcr31, dspcontrol; long epc; union mips_instruction insn; Loading @@ -33,7 +34,7 @@ int __compute_return_epc(struct pt_regs *regs) /* * Read the instruction */ addr = (unsigned int *) epc; addr = (unsigned int __user *) epc; if (__get_user(insn.word, addr)) { force_sig(SIGSEGV, current); return -EFAULT; Loading arch/mips/kernel/traps.c +1 −1 Original line number Diff line number Diff line Loading @@ -131,7 +131,7 @@ static void show_stacktrace(struct task_struct *task, struct pt_regs *regs) const int field = 2 * sizeof(unsigned long); long stackdata; int i; unsigned long *sp = (unsigned long *)regs->regs[29]; unsigned long __user *sp = (unsigned long __user *)regs->regs[29]; printk("Stack :"); i = 0; Loading arch/mips/math-emu/dsemul.c +6 −6 Original line number Diff line number Diff line Loading @@ -54,8 +54,7 @@ struct emuframe { int mips_dsemul(struct pt_regs *regs, mips_instruction ir, unsigned long cpc) { extern asmlinkage void handle_dsemulret(void); mips_instruction *dsemul_insns; struct emuframe *fr; struct emuframe __user *fr; int err; if (ir == 0) { /* a nop is easy */ Loading Loading @@ -87,8 +86,8 @@ int mips_dsemul(struct pt_regs *regs, mips_instruction ir, unsigned long cpc) */ /* Ensure that the two instructions are in the same cache line */ dsemul_insns = (mips_instruction *) ((regs->regs[29] - sizeof(struct emuframe)) & ~0x7); fr = (struct emuframe *) dsemul_insns; fr = (struct emuframe __user *) ((regs->regs[29] - sizeof(struct emuframe)) & ~0x7); /* Verify that the stack pointer is not competely insane */ if (unlikely(!access_ok(VERIFY_WRITE, fr, sizeof(struct emuframe)))) Loading @@ -113,12 +112,13 @@ int mips_dsemul(struct pt_regs *regs, mips_instruction ir, unsigned long cpc) int do_dsemulret(struct pt_regs *xcp) { struct emuframe *fr; struct emuframe __user *fr; unsigned long epc; u32 insn, cookie; int err = 0; fr = (struct emuframe *) (xcp->cp0_epc - sizeof(mips_instruction)); fr = (struct emuframe __user *) (xcp->cp0_epc - sizeof(mips_instruction)); /* * If we can't even access the area, something is very wrong, but we'll Loading Loading
arch/mips/kernel/branch.c +3 −2 Original line number Diff line number Diff line Loading @@ -22,7 +22,8 @@ */ int __compute_return_epc(struct pt_regs *regs) { unsigned int *addr, bit, fcr31, dspcontrol; unsigned int __user *addr; unsigned int bit, fcr31, dspcontrol; long epc; union mips_instruction insn; Loading @@ -33,7 +34,7 @@ int __compute_return_epc(struct pt_regs *regs) /* * Read the instruction */ addr = (unsigned int *) epc; addr = (unsigned int __user *) epc; if (__get_user(insn.word, addr)) { force_sig(SIGSEGV, current); return -EFAULT; Loading
arch/mips/kernel/traps.c +1 −1 Original line number Diff line number Diff line Loading @@ -131,7 +131,7 @@ static void show_stacktrace(struct task_struct *task, struct pt_regs *regs) const int field = 2 * sizeof(unsigned long); long stackdata; int i; unsigned long *sp = (unsigned long *)regs->regs[29]; unsigned long __user *sp = (unsigned long __user *)regs->regs[29]; printk("Stack :"); i = 0; Loading
arch/mips/math-emu/dsemul.c +6 −6 Original line number Diff line number Diff line Loading @@ -54,8 +54,7 @@ struct emuframe { int mips_dsemul(struct pt_regs *regs, mips_instruction ir, unsigned long cpc) { extern asmlinkage void handle_dsemulret(void); mips_instruction *dsemul_insns; struct emuframe *fr; struct emuframe __user *fr; int err; if (ir == 0) { /* a nop is easy */ Loading Loading @@ -87,8 +86,8 @@ int mips_dsemul(struct pt_regs *regs, mips_instruction ir, unsigned long cpc) */ /* Ensure that the two instructions are in the same cache line */ dsemul_insns = (mips_instruction *) ((regs->regs[29] - sizeof(struct emuframe)) & ~0x7); fr = (struct emuframe *) dsemul_insns; fr = (struct emuframe __user *) ((regs->regs[29] - sizeof(struct emuframe)) & ~0x7); /* Verify that the stack pointer is not competely insane */ if (unlikely(!access_ok(VERIFY_WRITE, fr, sizeof(struct emuframe)))) Loading @@ -113,12 +112,13 @@ int mips_dsemul(struct pt_regs *regs, mips_instruction ir, unsigned long cpc) int do_dsemulret(struct pt_regs *xcp) { struct emuframe *fr; struct emuframe __user *fr; unsigned long epc; u32 insn, cookie; int err = 0; fr = (struct emuframe *) (xcp->cp0_epc - sizeof(mips_instruction)); fr = (struct emuframe __user *) (xcp->cp0_epc - sizeof(mips_instruction)); /* * If we can't even access the area, something is very wrong, but we'll Loading