projects/linux·commit 299b4eaa

memcg: NULL pointer dereference at rmdir on some NUMA systems

299b4eaa · KAMEZAWA Hiroyuki <[email protected]> · 2009-01-29 14:25:17 -08:00

N_POSSIBLE doesn't means there is memory...and force_empty can
visit invalid node which have no pgdat.

To visit all valid nodes, N_HIGH_MEMORY should be used.

Reported-by: Li Zefan <[email protected]>
Signed-off-by: KAMEZAWA Hiroyuki <[email protected]>
Tested-by: Li Zefan <[email protected]>
Cc: Balbir Singh <[email protected]>
Cc: Daisuke Nishimura <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Commit
299b4eaa302138426d5a9ecd954de1f565d76c94
Parents
248ae0d4

Changes

1 files changed · +1 −1

FileStatusAddDelContent
mm/memcontrol.cmodified+1−1View file

mm/memcontrol.c

View file
diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index 76feccd..8e4be9c 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -1685,7 +1685,7 @@ move_account:
/* This is for making all *used* pages to be on LRU. */
lru_add_drain_all();
ret = 0;
- for_each_node_state(node, N_POSSIBLE) {
+ for_each_node_state(node, N_HIGH_MEMORY) {
for (zid = 0; !ret && zid < MAX_NR_ZONES; zid++) {
enum lru_list l;
for_each_lru(l) {