aboutsummaryrefslogtreecommitdiffstats
path: root/arch/um/kernel/trap.c
diff options
context:
space:
mode:
authorJeff Dike <jdike@addtoit.com>2007-02-10 04:44:14 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-11 13:51:22 -0500
commit27aa6ef3c0e8220b27b0a8d2d0bae7cd0a6d2f78 (patch)
tree322d8ee8ad1de886c33c1fda0bdd1c9cbab8a82a /arch/um/kernel/trap.c
parent6d1b18b16fc917e5c9af568a53c7e37923821d70 (diff)
[PATCH] uml: make signal handlers static
A bunch of the signal handlers can be made static. Signed-off-by: Jeff Dike <jdike@addtoit.com> Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/um/kernel/trap.c')
-rw-r--r--arch/um/kernel/trap.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/arch/um/kernel/trap.c b/arch/um/kernel/trap.c
index b5f124a2f6ae..26f15c458574 100644
--- a/arch/um/kernel/trap.c
+++ b/arch/um/kernel/trap.c
@@ -128,7 +128,18 @@ out_of_memory:
128 goto out; 128 goto out;
129} 129}
130 130
131void segv_handler(int sig, union uml_pt_regs *regs) 131static void bad_segv(struct faultinfo fi, unsigned long ip)
132{
133 struct siginfo si;
134
135 si.si_signo = SIGSEGV;
136 si.si_code = SEGV_ACCERR;
137 si.si_addr = (void __user *) FAULT_ADDRESS(fi);
138 current->thread.arch.faultinfo = fi;
139 force_sig_info(SIGSEGV, &si, current);
140}
141
142static void segv_handler(int sig, union uml_pt_regs *regs)
132{ 143{
133 struct faultinfo * fi = UPT_FAULTINFO(regs); 144 struct faultinfo * fi = UPT_FAULTINFO(regs);
134 145
@@ -205,17 +216,6 @@ unsigned long segv(struct faultinfo fi, unsigned long ip, int is_user, void *sc)
205 return(0); 216 return(0);
206} 217}
207 218
208void bad_segv(struct faultinfo fi, unsigned long ip)
209{
210 struct siginfo si;
211
212 si.si_signo = SIGSEGV;
213 si.si_code = SEGV_ACCERR;
214 si.si_addr = (void __user *) FAULT_ADDRESS(fi);
215 current->thread.arch.faultinfo = fi;
216 force_sig_info(SIGSEGV, &si, current);
217}
218
219void relay_signal(int sig, union uml_pt_regs *regs) 219void relay_signal(int sig, union uml_pt_regs *regs)
220{ 220{
221 if(arch_handle_signal(sig, regs)) 221 if(arch_handle_signal(sig, regs))
@@ -232,14 +232,14 @@ void relay_signal(int sig, union uml_pt_regs *regs)
232 force_sig(sig, current); 232 force_sig(sig, current);
233} 233}
234 234
235void bus_handler(int sig, union uml_pt_regs *regs) 235static void bus_handler(int sig, union uml_pt_regs *regs)
236{ 236{
237 if(current->thread.fault_catcher != NULL) 237 if(current->thread.fault_catcher != NULL)
238 do_longjmp(current->thread.fault_catcher, 1); 238 do_longjmp(current->thread.fault_catcher, 1);
239 else relay_signal(sig, regs); 239 else relay_signal(sig, regs);
240} 240}
241 241
242void winch(int sig, union uml_pt_regs *regs) 242static void winch(int sig, union uml_pt_regs *regs)
243{ 243{
244 do_IRQ(WINCH_IRQ, regs); 244 do_IRQ(WINCH_IRQ, regs);
245} 245}