Commit 53b50f94 authored by Al Viro's avatar Al Viro

powerpc: take dereferencing to ret_from_kernel_thread()

Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
parent 40792104
...@@ -373,6 +373,7 @@ _GLOBAL(ret_from_fork) ...@@ -373,6 +373,7 @@ _GLOBAL(ret_from_fork)
_GLOBAL(ret_from_kernel_thread) _GLOBAL(ret_from_kernel_thread)
bl .schedule_tail bl .schedule_tail
REST_NVGPRS(r1) REST_NVGPRS(r1)
ld r14, 0(r14)
mtlr r14 mtlr r14
mr r3,r15 mr r3,r15
blrl blrl
......
...@@ -749,12 +749,10 @@ int copy_thread(unsigned long clone_flags, unsigned long usp, ...@@ -749,12 +749,10 @@ int copy_thread(unsigned long clone_flags, unsigned long usp,
struct thread_info *ti = (void *)task_stack_page(p); struct thread_info *ti = (void *)task_stack_page(p);
memset(childregs, 0, sizeof(struct pt_regs)); memset(childregs, 0, sizeof(struct pt_regs));
childregs->gpr[1] = sp + sizeof(struct pt_regs); childregs->gpr[1] = sp + sizeof(struct pt_regs);
childregs->gpr[14] = usp; /* function */
#ifdef CONFIG_PPC64 #ifdef CONFIG_PPC64
childregs->gpr[14] = *(unsigned long *)usp;
clear_tsk_thread_flag(p, TIF_32BIT); clear_tsk_thread_flag(p, TIF_32BIT);
childregs->softe = 1; childregs->softe = 1;
#else
childregs->gpr[14] = usp; /* function */
#endif #endif
childregs->gpr[15] = arg; childregs->gpr[15] = arg;
p->thread.regs = NULL; /* no user register state */ p->thread.regs = NULL; /* no user register state */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment