aboutsummaryrefslogtreecommitdiffstats
path: root/arch/um/kernel/tt
diff options
context:
space:
mode:
authorJeff Dike <jdike@addtoit.com>2005-06-25 17:55:21 -0400
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-06-25 19:24:35 -0400
commite0877f07e85a46e4fde32bd84f08551d360839fe (patch)
tree97e29c30e5f1ee7f06f5cdd4760291d3bba6640e /arch/um/kernel/tt
parent41f2148a67f28803d64bf5ff538591af90a5ab57 (diff)
[PATCH] uml: fork cleanup
Fix the do_fork calling convention: normal arch pass the regs and the new sp value to do_fork instead of NULL. Currently the arch-independent code ignores these values, while the UML code (actually it's copy_thread) gets the right values by itself. With this patch, things are fixed up. Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Signed-off-by: Jeff Dike <jdike@addtoit.com> Cc: Paolo Giarrusso <blaisorblade@yahoo.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/um/kernel/tt')
-rw-r--r--arch/um/kernel/tt/process_kern.c17
1 files changed, 3 insertions, 14 deletions
diff --git a/arch/um/kernel/tt/process_kern.c b/arch/um/kernel/tt/process_kern.c
index 776310fd5b8b..a189a2b92935 100644
--- a/arch/um/kernel/tt/process_kern.c
+++ b/arch/um/kernel/tt/process_kern.c
@@ -266,10 +266,10 @@ int copy_thread_tt(int nr, unsigned long clone_flags, unsigned long sp,
266 } 266 }
267 267
268 if(current->thread.forking){ 268 if(current->thread.forking){
269 sc_to_sc(UPT_SC(&p->thread.regs.regs), 269 sc_to_sc(UPT_SC(&p->thread.regs.regs), UPT_SC(&regs->regs));
270 UPT_SC(&current->thread.regs.regs));
271 SC_SET_SYSCALL_RETURN(UPT_SC(&p->thread.regs.regs), 0); 270 SC_SET_SYSCALL_RETURN(UPT_SC(&p->thread.regs.regs), 0);
272 if(sp != 0) SC_SP(UPT_SC(&p->thread.regs.regs)) = sp; 271 if(sp != 0)
272 SC_SP(UPT_SC(&p->thread.regs.regs)) = sp;
273 } 273 }
274 p->thread.mode.tt.extern_pid = new_pid; 274 p->thread.mode.tt.extern_pid = new_pid;
275 275
@@ -459,14 +459,3 @@ int is_valid_pid(int pid)
459 read_unlock(&tasklist_lock); 459 read_unlock(&tasklist_lock);
460 return(0); 460 return(0);
461} 461}
462
463/*
464 * Overrides for Emacs so that we follow Linus's tabbing style.
465 * Emacs will notice this stuff at the end of the file and automatically
466 * adjust the settings for this buffer only. This must remain at the end
467 * of the file.
468 * ---------------------------------------------------------------------------
469 * Local variables:
470 * c-file-style: "linux"
471 * End:
472 */