diff options
author | Christoph Hellwig <hch@lst.de> | 2007-05-08 03:27:03 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-08 14:15:04 -0400 |
commit | 1eeb66a1bb973534dc3d064920a5ca683823372e (patch) | |
tree | 19c22d611e6adefb352dbc107b859e4d13ba38c1 /arch/s390/kernel | |
parent | e3869792990f708c97be5877499cada70d469bd3 (diff) |
move die notifier handling to common code
This patch moves the die notifier handling to common code. Previous
various architectures had exactly the same code for it. Note that the new
code is compiled unconditionally, this should be understood as an appel to
the other architecture maintainer to implement support for it aswell (aka
sprinkling a notify_die or two in the proper place)
arm had a notifiy_die that did something totally different, I renamed it to
arm_notify_die as part of the patch and made it static to the file it's
declared and used at. avr32 used to pass slightly less information through
this interface and I brought it into line with the other architectures.
[akpm@linux-foundation.org: build fix]
[akpm@linux-foundation.org: fix vmalloc_sync_all bustage]
[bryan.wu@analog.com: fix vmalloc_sync_all in nommu]
Signed-off-by: Christoph Hellwig <hch@lst.de>
Cc: <linux-arch@vger.kernel.org>
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/s390/kernel')
-rw-r--r-- | arch/s390/kernel/kprobes.c | 2 | ||||
-rw-r--r-- | arch/s390/kernel/traps.c | 16 |
2 files changed, 2 insertions, 16 deletions
diff --git a/arch/s390/kernel/kprobes.c b/arch/s390/kernel/kprobes.c index 23c61f6d965b..8516a94d8163 100644 --- a/arch/s390/kernel/kprobes.c +++ b/arch/s390/kernel/kprobes.c | |||
@@ -24,8 +24,8 @@ | |||
24 | #include <linux/ptrace.h> | 24 | #include <linux/ptrace.h> |
25 | #include <linux/preempt.h> | 25 | #include <linux/preempt.h> |
26 | #include <linux/stop_machine.h> | 26 | #include <linux/stop_machine.h> |
27 | #include <linux/kdebug.h> | ||
27 | #include <asm/cacheflush.h> | 28 | #include <asm/cacheflush.h> |
28 | #include <asm/kdebug.h> | ||
29 | #include <asm/sections.h> | 29 | #include <asm/sections.h> |
30 | #include <asm/uaccess.h> | 30 | #include <asm/uaccess.h> |
31 | #include <linux/module.h> | 31 | #include <linux/module.h> |
diff --git a/arch/s390/kernel/traps.c b/arch/s390/kernel/traps.c index 49dec830373a..a750bcc69aaa 100644 --- a/arch/s390/kernel/traps.c +++ b/arch/s390/kernel/traps.c | |||
@@ -27,6 +27,7 @@ | |||
27 | #include <linux/interrupt.h> | 27 | #include <linux/interrupt.h> |
28 | #include <linux/delay.h> | 28 | #include <linux/delay.h> |
29 | #include <linux/module.h> | 29 | #include <linux/module.h> |
30 | #include <linux/kdebug.h> | ||
30 | #include <linux/kallsyms.h> | 31 | #include <linux/kallsyms.h> |
31 | #include <linux/reboot.h> | 32 | #include <linux/reboot.h> |
32 | #include <linux/kprobes.h> | 33 | #include <linux/kprobes.h> |
@@ -40,7 +41,6 @@ | |||
40 | #include <asm/s390_ext.h> | 41 | #include <asm/s390_ext.h> |
41 | #include <asm/lowcore.h> | 42 | #include <asm/lowcore.h> |
42 | #include <asm/debug.h> | 43 | #include <asm/debug.h> |
43 | #include <asm/kdebug.h> | ||
44 | 44 | ||
45 | /* Called from entry.S only */ | 45 | /* Called from entry.S only */ |
46 | extern void handle_per_exception(struct pt_regs *regs); | 46 | extern void handle_per_exception(struct pt_regs *regs); |
@@ -70,20 +70,6 @@ static int kstack_depth_to_print = 12; | |||
70 | static int kstack_depth_to_print = 20; | 70 | static int kstack_depth_to_print = 20; |
71 | #endif /* CONFIG_64BIT */ | 71 | #endif /* CONFIG_64BIT */ |
72 | 72 | ||
73 | ATOMIC_NOTIFIER_HEAD(s390die_chain); | ||
74 | |||
75 | int register_die_notifier(struct notifier_block *nb) | ||
76 | { | ||
77 | return atomic_notifier_chain_register(&s390die_chain, nb); | ||
78 | } | ||
79 | EXPORT_SYMBOL(register_die_notifier); | ||
80 | |||
81 | int unregister_die_notifier(struct notifier_block *nb) | ||
82 | { | ||
83 | return atomic_notifier_chain_unregister(&s390die_chain, nb); | ||
84 | } | ||
85 | EXPORT_SYMBOL(unregister_die_notifier); | ||
86 | |||
87 | /* | 73 | /* |
88 | * For show_trace we have tree different stack to consider: | 74 | * For show_trace we have tree different stack to consider: |
89 | * - the panic stack which is used if the kernel stack has overflown | 75 | * - the panic stack which is used if the kernel stack has overflown |