aboutsummaryrefslogtreecommitdiffstats
path: root/arch/s390/kernel/entry.h
diff options
context:
space:
mode:
authorMartin Schwidefsky <schwidefsky@de.ibm.com>2012-03-11 11:59:26 -0400
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2012-03-11 11:59:28 -0400
commit8b646bd759086f6090fe27acf414c0b5faa737f4 (patch)
tree29475659031c57ccf2ca43899614ab5c6b1899a0 /arch/s390/kernel/entry.h
parent7e180bd8020d213bb0de15c3606968f8a9262439 (diff)
[S390] rework smp code
Define struct pcpu and merge some of the NR_CPUS arrays into it, including __cpu_logical_map, current_set and smp_cpu_state. Split smp related functions to those operating on physical cpus and the functions operating on a logical cpu number. Make the functions for physical cpus use a pointer to a struct pcpu. This hides the knowledge about cpu addresses in smp.c, entry[64].S and swsusp_asm64.S, thus remove the sigp.h header. The PSW restart mechanism is used to start secondary cpus, calling a function on an online cpu, calling a function on the ipl cpu, and for the nmi signal. Replace the different assembler functions with a single function restart_int_handler. The new entry point calls a function whose pointer is stored in the lowcore of the target cpu and it can wait for the source cpu to stop. This covers all existing use cases. Overall the code is now simpler and there are ~380 lines less code. Reviewed-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'arch/s390/kernel/entry.h')
-rw-r--r--arch/s390/kernel/entry.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/arch/s390/kernel/entry.h b/arch/s390/kernel/entry.h
index bf538aaf407d..92b1617d0c95 100644
--- a/arch/s390/kernel/entry.h
+++ b/arch/s390/kernel/entry.h
@@ -9,6 +9,14 @@
9extern void (*pgm_check_table[128])(struct pt_regs *); 9extern void (*pgm_check_table[128])(struct pt_regs *);
10extern void *restart_stack; 10extern void *restart_stack;
11 11
12void system_call(void);
13void pgm_check_handler(void);
14void ext_int_handler(void);
15void io_int_handler(void);
16void mcck_int_handler(void);
17void restart_int_handler(void);
18void restart_call_handler(void);
19
12asmlinkage long do_syscall_trace_enter(struct pt_regs *regs); 20asmlinkage long do_syscall_trace_enter(struct pt_regs *regs);
13asmlinkage void do_syscall_trace_exit(struct pt_regs *regs); 21asmlinkage void do_syscall_trace_exit(struct pt_regs *regs);
14 22
@@ -26,7 +34,6 @@ void do_notify_resume(struct pt_regs *regs);
26 34
27void do_extint(struct pt_regs *regs, unsigned int, unsigned int, unsigned long); 35void do_extint(struct pt_regs *regs, unsigned int, unsigned int, unsigned long);
28void do_restart(void); 36void do_restart(void);
29int __cpuinit start_secondary(void *cpuvoid);
30void __init startup_init(void); 37void __init startup_init(void);
31void die(struct pt_regs *regs, const char *str); 38void die(struct pt_regs *regs, const char *str);
32 39