aboutsummaryrefslogtreecommitdiffstats
path: root/arch/um/sys-i386/ptrace.c
diff options
context:
space:
mode:
authorPaolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>2006-03-31 05:30:24 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2006-03-31 15:18:52 -0500
commit54d8d3b5a0ce1cdbad1d3154c9ea9732d394e9c7 (patch)
tree129a29ab92fba7dc99229c87a38fe8df3ade7b15 /arch/um/sys-i386/ptrace.c
parentdd77aec07aec5cb81aed3b4ef79c1ff8bd0e2a68 (diff)
[PATCH] uml: add arch_switch_to for newly forked thread
Newly forked threads have no arch_switch_to_skas() called before their first run, because when schedule() switches to them they're resumed in the body of thread_wait() inside fork_handler() rather than in switch_threads() in switch_to_skas(). Compensate this missing call. Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Acked-by: Jeff Dike <jdike@addtoit.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/um/sys-i386/ptrace.c')
-rw-r--r--arch/um/sys-i386/ptrace.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/arch/um/sys-i386/ptrace.c b/arch/um/sys-i386/ptrace.c
index 6a23cc6947c3..6028bc7cc01b 100644
--- a/arch/um/sys-i386/ptrace.c
+++ b/arch/um/sys-i386/ptrace.c
@@ -23,7 +23,14 @@ void arch_switch_to_tt(struct task_struct *from, struct task_struct *to)
23 23
24void arch_switch_to_skas(struct task_struct *from, struct task_struct *to) 24void arch_switch_to_skas(struct task_struct *from, struct task_struct *to)
25{ 25{
26 arch_switch_tls_skas(from, to); 26 int err = arch_switch_tls_skas(from, to);
27 if (!err)
28 return;
29
30 if (err != -EINVAL)
31 printk(KERN_WARNING "arch_switch_tls_skas failed, errno %d, not EINVAL\n", -err);
32 else
33 printk(KERN_WARNING "arch_switch_tls_skas failed, errno = EINVAL\n");
27} 34}
28 35
29int is_syscall(unsigned long addr) 36int is_syscall(unsigned long addr)