linux-mips-fnet
[Top] [All Lists]

Re: Problems w/ 2.1.131 on r3k

To: linux-mips@fnet.fr
Subject: Re: Problems w/ 2.1.131 on r3k
From: "Gleb O. Raiko" <raiko@niisi.msk.ru>
Date: Thu, 28 Jan 1999 16:21:55 +0300
Cc: ralf@uni-koblenz.de
Organization: NIISI RAN
References: <36AC8C20.F3225338@niisi.msk.ru> <19990126014109.K558@uni-koblenz.de>
ralf@uni-koblenz.de wrote:
> 
> Syscall restarting for syscalls with four or more arguments won't work, the
> fourth argument will be corrupted before return from kernel mode.  The
> following changes to arch/mips/kernel/{signal.c,scall_o32.S} should fix
> that:
> 
> [...]
>         case ERESTARTNOINTR:            /* Userland will reload $v0.  */
>                 regs->regs[7] = regs->regs[26];
>                 regs->cp0_epc -= 8;
>         }
> [...]
> stack_done:
>         sw      a3, PT_R26($28)         # save for syscall restart
>         lw      t0, TASK_FLAGS($28)     # syscall tracing enabled?
>         andi    t0, PF_TRACESYS
> [...]
> 

With one correction:

stack_done:
-       sw      a3, PT_R26($28)         # save for syscall restart
+       sw      a3, PT_R26(sp)          # save for syscall restart

if you don't want to corrupt a current task struct :-)

Ralf, was it just a typo ?

With this fix, 2.1.131 seems to be stable for us.

Regards,
Gleb.

<Prev in Thread] Current Thread [Next in Thread>