Commit 299b4eaa authored by KAMEZAWA Hiroyuki's avatar KAMEZAWA Hiroyuki Committed by Linus Torvalds
Browse files

memcg: NULL pointer dereference at rmdir on some NUMA systems

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: default avatarLi Zefan <>
Signed-off-by: default avatarKAMEZAWA Hiroyuki <>
Tested-by: default avatarLi Zefan <>
Cc: Balbir Singh <>
Cc: Daisuke Nishimura <>
Signed-off-by: default avatarAndrew Morton <>
Signed-off-by: default avatarLinus Torvalds <>
parent 248ae0d4
......@@ -1685,7 +1685,7 @@ move_account:
/* This is for making all *used* pages to be on LRU. */
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) {
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment