diff options
author | KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> | 2009-09-22 19:45:44 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-09-23 10:39:41 -0400 |
commit | a0614da88b67ffa3dbcc0d40b817e682c7c4a0ee (patch) | |
tree | ae4ca3a8553592af41f7c2cc1a64912d934f6baf /fs/proc | |
parent | c30bb2a25fcfde6157e6154a32c14686fb0bedbe (diff) |
kcore: register vmalloc area in generic way
For /proc/kcore, vmalloc areas are registered per arch. But, all of them
registers same range of [VMALLOC_START...VMALLOC_END) This patch unifies
them. By this. archs which have no kclist_add() hooks can see vmalloc
area correctly.
Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: WANG Cong <xiyou.wangcong@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/proc')
-rw-r--r-- | fs/proc/kcore.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/proc/kcore.c b/fs/proc/kcore.c index 659c1635db81..e10d360110bd 100644 --- a/fs/proc/kcore.c +++ b/fs/proc/kcore.c | |||
@@ -372,9 +372,14 @@ read_kcore(struct file *file, char __user *buffer, size_t buflen, loff_t *fpos) | |||
372 | return acc; | 372 | return acc; |
373 | } | 373 | } |
374 | 374 | ||
375 | static struct kcore_list kcore_vmalloc; | ||
376 | |||
375 | static int __init proc_kcore_init(void) | 377 | static int __init proc_kcore_init(void) |
376 | { | 378 | { |
377 | proc_root_kcore = proc_create("kcore", S_IRUSR, NULL, &proc_kcore_operations); | 379 | proc_root_kcore = proc_create("kcore", S_IRUSR, NULL, &proc_kcore_operations); |
380 | |||
381 | kclist_add(&kcore_vmalloc, (void *)VMALLOC_START, | ||
382 | VMALLOC_END - VMALLOC_START, KCORE_VMALLOC); | ||
378 | return 0; | 383 | return 0; |
379 | } | 384 | } |
380 | module_init(proc_kcore_init); | 385 | module_init(proc_kcore_init); |