diff options
author | Gennady Sharapov <Gennady.V.Sharapov@intel.com> | 2006-01-08 04:01:31 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-01-08 23:13:39 -0500 |
commit | ea2ba7dc3dd3f85034e6da6abacc813d723a2ad5 (patch) | |
tree | 56f3d2a22d3ba3d91042d9a536b659b9c967dc03 /arch/um/kernel/tt | |
parent | 0805d89c151b4800eade4c2f50d39c5253d7d054 (diff) |
[PATCH] uml: move libc-dependent code from trap_user.c
The serial UML OS-abstraction layer patch (um/kernel dir).
This moves all systemcalls from trap_user.c file under os-Linux dir
Signed-off-by: Gennady Sharapov <Gennady.V.Sharapov@intel.com>
Signed-off-by: Jeff Dike <jdike@addtoit.com>
Cc: Paolo 'Blaisorblade' 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/trap_user.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/arch/um/kernel/tt/trap_user.c b/arch/um/kernel/tt/trap_user.c index 7501900f8941..a414c529fbcd 100644 --- a/arch/um/kernel/tt/trap_user.c +++ b/arch/um/kernel/tt/trap_user.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* | 1 | /* |
2 | * Copyright (C) 2002 Jeff Dike (jdike@karaya.com) | 2 | * Copyright (C) 2002 Jeff Dike (jdike@karaya.com) |
3 | * Licensed under the GPL | 3 | * Licensed under the GPL |
4 | */ | 4 | */ |
@@ -18,8 +18,8 @@ void sig_handler_common_tt(int sig, void *sc_ptr) | |||
18 | { | 18 | { |
19 | struct sigcontext *sc = sc_ptr; | 19 | struct sigcontext *sc = sc_ptr; |
20 | struct tt_regs save_regs, *r; | 20 | struct tt_regs save_regs, *r; |
21 | struct signal_info *info; | ||
22 | int save_errno = errno, is_user; | 21 | int save_errno = errno, is_user; |
22 | void (*handler)(int, union uml_pt_regs *); | ||
23 | 23 | ||
24 | /* This is done because to allow SIGSEGV to be delivered inside a SEGV | 24 | /* This is done because to allow SIGSEGV to be delivered inside a SEGV |
25 | * handler. This can happen in copy_user, and if SEGV is disabled, | 25 | * handler. This can happen in copy_user, and if SEGV is disabled, |
@@ -40,10 +40,14 @@ void sig_handler_common_tt(int sig, void *sc_ptr) | |||
40 | if(sig != SIGUSR2) | 40 | if(sig != SIGUSR2) |
41 | r->syscall = -1; | 41 | r->syscall = -1; |
42 | 42 | ||
43 | info = &sig_info[sig]; | 43 | handler = sig_info[sig]; |
44 | if(!info->is_irq) unblock_signals(); | 44 | |
45 | /* unblock SIGALRM, SIGVTALRM, SIGIO if sig isn't IRQ signal */ | ||
46 | if (sig != SIGIO && sig != SIGWINCH && | ||
47 | sig != SIGVTALRM && sig != SIGALRM) | ||
48 | unblock_signals(); | ||
45 | 49 | ||
46 | (*info->handler)(sig, (union uml_pt_regs *) r); | 50 | handler(sig, (union uml_pt_regs *) r); |
47 | 51 | ||
48 | if(is_user){ | 52 | if(is_user){ |
49 | interrupt_end(); | 53 | interrupt_end(); |