diff options
author | Vivek Goyal <vgoyal@in.ibm.com> | 2006-01-09 23:51:42 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-01-10 11:01:26 -0500 |
commit | 51be5606d9ff9eb27ed6514f6172fbd7578a25d6 (patch) | |
tree | 8020841fc1eb4fa4603870913385eb9253de7d2e /kernel | |
parent | cc57165874e938ef684d71ba7d36e7088b551489 (diff) |
[PATCH] kdump: export per cpu crash notes pointer through sysfs
- Kexec on panic functionality allocates memory for saving cpu registers in
case of system crash event. Address of this allocated memory needs to be
exported to user space, which is used by kexec-tools.
- Previously, a single /sys/kernel/crash_notes entry was being exported as
memory allocated was a single continuous array. Now memory allocation being
dyanmic and per cpu based, address of per cpu buffer is exported through
"/sys/devices/system/cpu/cpuX/crash_notes"
Signed-off-by: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/ksysfs.c | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/kernel/ksysfs.c b/kernel/ksysfs.c index 99af8b05eeaa..d5eeae0fa5bc 100644 --- a/kernel/ksysfs.c +++ b/kernel/ksysfs.c | |||
@@ -51,16 +51,6 @@ static ssize_t uevent_helper_store(struct subsystem *subsys, const char *page, s | |||
51 | KERNEL_ATTR_RW(uevent_helper); | 51 | KERNEL_ATTR_RW(uevent_helper); |
52 | #endif | 52 | #endif |
53 | 53 | ||
54 | #ifdef CONFIG_KEXEC | ||
55 | #include <asm/kexec.h> | ||
56 | |||
57 | static ssize_t crash_notes_show(struct subsystem *subsys, char *page) | ||
58 | { | ||
59 | return sprintf(page, "%p\n", (void *)crash_notes); | ||
60 | } | ||
61 | KERNEL_ATTR_RO(crash_notes); | ||
62 | #endif | ||
63 | |||
64 | decl_subsys(kernel, NULL, NULL); | 54 | decl_subsys(kernel, NULL, NULL); |
65 | EXPORT_SYMBOL_GPL(kernel_subsys); | 55 | EXPORT_SYMBOL_GPL(kernel_subsys); |
66 | 56 | ||
@@ -69,9 +59,6 @@ static struct attribute * kernel_attrs[] = { | |||
69 | &uevent_seqnum_attr.attr, | 59 | &uevent_seqnum_attr.attr, |
70 | &uevent_helper_attr.attr, | 60 | &uevent_helper_attr.attr, |
71 | #endif | 61 | #endif |
72 | #ifdef CONFIG_KEXEC | ||
73 | &crash_notes_attr.attr, | ||
74 | #endif | ||
75 | NULL | 62 | NULL |
76 | }; | 63 | }; |
77 | 64 | ||