projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
78f508a
)
make vmstat cpu-unplug safe
author
KOSAKI Motohiro
<
[email protected]
>
Mon, 12 May 2008 21:02:06 +0000
(14:02 -0700)
committer
Linus Torvalds
<
[email protected]
>
Tue, 13 May 2008 15:02:23 +0000
(08:02 -0700)
When accessing cpu_online_map, we should prevent dynamic changing
of cpu_online_map by get_online_cpus().
Unfortunately, all_vm_events() doesn't do that.
Signed-off-by: KOSAKI Motohiro <
[email protected]
>
Acked-by: Christoph Lameter <
[email protected]
>
Cc: Gautham R Shenoy <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
mm/vmstat.c
patch
|
blob
|
history
diff --git
a/mm/vmstat.c
b/mm/vmstat.c
index 1a32130b958c418ec8a018aa676c73bb3d7cde32..db9eabb2c5b3a992a04ac2396bf791b72bbdcf94 100644
(file)
--- a/
mm/vmstat.c
+++ b/
mm/vmstat.c
@@
-41,7
+41,9
@@
static void sum_vm_events(unsigned long *ret, cpumask_t *cpumask)
*/
void all_vm_events(unsigned long *ret)
{
+ get_online_cpus();
sum_vm_events(ret, &cpu_online_map);
+ put_online_cpus();
}
EXPORT_SYMBOL_GPL(all_vm_events);