aboutsummaryrefslogtreecommitdiffstats
path: root/arch/um/include/kern_util.h
diff options
context:
space:
mode:
authorJeff Dike <jdike@addtoit.com>2007-05-06 17:51:21 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-05-07 15:13:02 -0400
commit6e21aec3fcf6c8862b755d45c0af45acdefff976 (patch)
tree1e2bcf6ae8ac4a6e62766cb1cddf073410d4ea5c /arch/um/include/kern_util.h
parent65a58ab044308ae65ca06c50fb10be5e0e080989 (diff)
uml: tidy process.c
Clean up arch/um/kernel/process.c: - lots of return(x); -> return x; conversions - a number of the small functions are either unused, in which case they are gone, along any declarations in a header, or could be made static. - current_pid is ifdefed on CONFIG_MODE_TT and its declaration is ifdefed on both CONFIG_MODE_TT and UML_CONFIG_MODE_TT because we don't know whether it's being used in a userspace or kernel file. Signed-off-by: Jeff Dike <jdike@linux.intel.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/include/kern_util.h')
-rw-r--r--arch/um/include/kern_util.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/arch/um/include/kern_util.h b/arch/um/include/kern_util.h
index be850b9ec947..09810bc48e5b 100644
--- a/arch/um/include/kern_util.h
+++ b/arch/um/include/kern_util.h
@@ -8,6 +8,7 @@
8 8
9#include "sysdep/ptrace.h" 9#include "sysdep/ptrace.h"
10#include "sysdep/faultinfo.h" 10#include "sysdep/faultinfo.h"
11#include "uml-config.h"
11 12
12typedef void (*kern_hndl)(int, union uml_pt_regs *); 13typedef void (*kern_hndl)(int, union uml_pt_regs *);
13 14
@@ -33,7 +34,9 @@ extern int nsyscalls;
33 UML_ROUND_DOWN(((unsigned long) addr) + PAGE_SIZE - 1) 34 UML_ROUND_DOWN(((unsigned long) addr) + PAGE_SIZE - 1)
34 35
35extern int kernel_fork(unsigned long flags, int (*fn)(void *), void * arg); 36extern int kernel_fork(unsigned long flags, int (*fn)(void *), void * arg);
37#ifdef UML_CONFIG_MODE_TT
36extern unsigned long stack_sp(unsigned long page); 38extern unsigned long stack_sp(unsigned long page);
39#endif
37extern int kernel_thread_proc(void *data); 40extern int kernel_thread_proc(void *data);
38extern void syscall_segv(int sig); 41extern void syscall_segv(int sig);
39extern int current_pid(void); 42extern int current_pid(void);
@@ -57,7 +60,6 @@ extern void add_input_request(int op, void (*proc)(int), void *arg);
57extern char *current_cmd(void); 60extern char *current_cmd(void);
58extern void timer_handler(int sig, union uml_pt_regs *regs); 61extern void timer_handler(int sig, union uml_pt_regs *regs);
59extern int set_signals(int enable); 62extern int set_signals(int enable);
60extern void force_sigbus(void);
61extern int pid_to_processor_id(int pid); 63extern int pid_to_processor_id(int pid);
62extern void deliver_signals(void *t); 64extern void deliver_signals(void *t);
63extern int next_trap_index(int max); 65extern int next_trap_index(int max);
@@ -69,7 +71,6 @@ extern void *syscall_sp(void *t);
69extern void syscall_trace(union uml_pt_regs *regs, int entryexit); 71extern void syscall_trace(union uml_pt_regs *regs, int entryexit);
70extern int hz(void); 72extern int hz(void);
71extern unsigned int do_IRQ(int irq, union uml_pt_regs *regs); 73extern unsigned int do_IRQ(int irq, union uml_pt_regs *regs);
72extern int external_pid(void *t);
73extern void interrupt_end(void); 74extern void interrupt_end(void);
74extern void initial_thread_cb(void (*proc)(void *), void *arg); 75extern void initial_thread_cb(void (*proc)(void *), void *arg);
75extern int debugger_signal(int status, int pid); 76extern int debugger_signal(int status, int pid);
@@ -80,7 +81,6 @@ extern int init_parent_proxy(int pid);
80extern int singlestepping(void *t); 81extern int singlestepping(void *t);
81extern void check_stack_overflow(void *ptr); 82extern void check_stack_overflow(void *ptr);
82extern void relay_signal(int sig, union uml_pt_regs *regs); 83extern void relay_signal(int sig, union uml_pt_regs *regs);
83extern void not_implemented(void);
84extern int user_context(unsigned long sp); 84extern int user_context(unsigned long sp);
85extern void timer_irq(union uml_pt_regs *regs); 85extern void timer_irq(union uml_pt_regs *regs);
86extern void unprotect_stack(unsigned long stack); 86extern void unprotect_stack(unsigned long stack);
@@ -92,7 +92,6 @@ extern char *uml_strdup(char *string);
92extern void unprotect_kernel_mem(void); 92extern void unprotect_kernel_mem(void);
93extern void protect_kernel_mem(void); 93extern void protect_kernel_mem(void);
94extern void uml_cleanup(void); 94extern void uml_cleanup(void);
95extern void set_current(void *t);
96extern void lock_signalled_task(void *t); 95extern void lock_signalled_task(void *t);
97extern void IPI_handler(int cpu); 96extern void IPI_handler(int cpu);
98extern int jail_setup(char *line, int *add); 97extern int jail_setup(char *line, int *add);