[PATCH] powerpc: Fix error path in kernel_thread function

Paul Mackerras paulus at samba.org
Thu Oct 9 13:57:37 EST 2008


Josh Boyer writes:

> From: Josh Poimboeuf <jpoimboe at us.ibm.com>
> 
> The powerpc 32-bit and 64-bit kernel_thread functions don't properly
> propagate errors being returned by the clone syscall.  (In the case of
> error, the syscall exit code returns a positive errno in r3 and sets
> the CR0[SO] bit.)
> 
> This patch fixes that by negating r3 if CR0[SO] is set after the syscall.
> 
> Signed-off-by: Josh Poimboeuf <jpoimboe at us.ibm.com>
> Signed-off-by: Josh Boyer <jwboyer at linux.vnet.ibm.com>

Acked-by: Paul Mackerras <paulus at samba.org>



More information about the Linuxppc-dev mailing list