diff options
author | Jeff Dike <jdike@addtoit.com> | 2005-06-25 17:55:21 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-25 19:24:35 -0400 |
commit | e0877f07e85a46e4fde32bd84f08551d360839fe (patch) | |
tree | 97e29c30e5f1ee7f06f5cdd4760291d3bba6640e /arch/um/kernel/skas | |
parent | 41f2148a67f28803d64bf5ff538591af90a5ab57 (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/skas')
-rw-r--r-- | arch/um/kernel/skas/process_kern.c | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/arch/um/kernel/skas/process_kern.c b/arch/um/kernel/skas/process_kern.c index fc71ef295782..8f0607f54b7a 100644 --- a/arch/um/kernel/skas/process_kern.c +++ b/arch/um/kernel/skas/process_kern.c | |||
@@ -111,8 +111,7 @@ int copy_thread_skas(int nr, unsigned long clone_flags, unsigned long sp, | |||
111 | void (*handler)(int); | 111 | void (*handler)(int); |
112 | 112 | ||
113 | if(current->thread.forking){ | 113 | if(current->thread.forking){ |
114 | memcpy(&p->thread.regs.regs.skas, | 114 | memcpy(&p->thread.regs.regs.skas, ®s->regs.skas, |
115 | ¤t->thread.regs.regs.skas, | ||
116 | sizeof(p->thread.regs.regs.skas)); | 115 | sizeof(p->thread.regs.regs.skas)); |
117 | REGS_SET_SYSCALL_RETURN(p->thread.regs.regs.skas.regs, 0); | 116 | REGS_SET_SYSCALL_RETURN(p->thread.regs.regs.skas.regs, 0); |
118 | if(sp != 0) REGS_SP(p->thread.regs.regs.skas.regs) = sp; | 117 | if(sp != 0) REGS_SP(p->thread.regs.regs.skas.regs) = sp; |
@@ -201,14 +200,3 @@ int thread_pid_skas(struct task_struct *task) | |||
201 | #warning Need to look up userspace_pid by cpu | 200 | #warning Need to look up userspace_pid by cpu |
202 | return(userspace_pid[0]); | 201 | return(userspace_pid[0]); |
203 | } | 202 | } |
204 | |||
205 | /* | ||
206 | * Overrides for Emacs so that we follow Linus's tabbing style. | ||
207 | * Emacs will notice this stuff at the end of the file and automatically | ||
208 | * adjust the settings for this buffer only. This must remain at the end | ||
209 | * of the file. | ||
210 | * --------------------------------------------------------------------------- | ||
211 | * Local variables: | ||
212 | * c-file-style: "linux" | ||
213 | * End: | ||
214 | */ | ||