Fix one more case of computing the return EPC after the registers have
authorRalf Baechle <ralf@linux-mips.org>
Tue, 12 Apr 2005 20:26:05 +0000 (20:26 +0000)
committerRalf Baechle <ralf@linux-mips.org>
Sat, 29 Oct 2005 18:31:04 +0000 (19:31 +0100)
already been modified.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/kernel/traps.c

index 77f796b..94d9141 100644 (file)
@@ -447,9 +447,9 @@ static inline void simulate_sc(struct pt_regs *regs, unsigned int opcode)
        preempt_disable();
 
        if (ll_bit == 0 || ll_task != current) {
+               compute_return_epc(regs);
                regs->regs[reg] = 0;
                preempt_enable();
-               compute_return_epc(regs);
                return;
        }