OSDN Git Service

rx: usp update fix
authorYoshinori Sato <ysato@users.sourceforge.jp>
Fri, 1 Jan 2016 11:39:07 +0000 (20:39 +0900)
committerYoshinori Sato <yo-satoh@sios.com>
Fri, 28 Jan 2022 13:08:35 +0000 (22:08 +0900)
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
arch/rx/kernel/process.c

index 905702e..ab5dc6d 100644 (file)
@@ -109,7 +109,8 @@ int copy_thread(unsigned long clone_flags,
                *childregs = *current_pt_regs();
                childregs->r[1] = 0;
                p->thread.pc = (unsigned long)ret_from_fork;
-               childregs->usp  = usp;
+               if(usp)
+                       childregs->usp  = usp;
        }
 
        p->thread.sp = (unsigned long)childregs;