path: root/mm/oom_kill.c
diff options
authorJoonsoo Kim <>2020-06-03 15:59:01 -0700
committerLinus Torvalds <>2020-06-03 20:09:44 -0700
commit97a225e69a1f880886f33d2e65a7ace13f152caa (patch)
tree5827c459fb9543eeb1ffec6b40edabf5f09e80ab /mm/oom_kill.c
parent3334a45eb9e2bb040c880ef65e1d72357a0a008b (diff)
mm/page_alloc: integrate classzone_idx and high_zoneidx
classzone_idx is just different name for high_zoneidx now. So, integrate them and add some comment to struct alloc_context in order to reduce future confusion about the meaning of this variable. The accessor, ac_classzone_idx() is also removed since it isn't needed after integration. In addition to integration, this patch also renames high_zoneidx to highest_zoneidx since it represents more precise meaning. Signed-off-by: Joonsoo Kim <> Signed-off-by: Andrew Morton <> Reviewed-by: Baoquan He <> Acked-by: Vlastimil Babka <> Acked-by: David Rientjes <> Cc: Johannes Weiner <> Cc: Mel Gorman <> Cc: Michal Hocko <> Cc: Minchan Kim <> Cc: Ye Xiaolong <> Link: Signed-off-by: Linus Torvalds <>
Diffstat (limited to 'mm/oom_kill.c')
1 files changed, 2 insertions, 2 deletions
diff --git a/mm/oom_kill.c b/mm/oom_kill.c
index dfc357614e56..4daedf7b91f6 100644
--- a/mm/oom_kill.c
+++ b/mm/oom_kill.c
@@ -254,7 +254,7 @@ static enum oom_constraint constrained_alloc(struct oom_control *oc)
struct zone *zone;
struct zoneref *z;
- enum zone_type high_zoneidx = gfp_zone(oc->gfp_mask);
+ enum zone_type highest_zoneidx = gfp_zone(oc->gfp_mask);
bool cpuset_limited = false;
int nid;
@@ -294,7 +294,7 @@ static enum oom_constraint constrained_alloc(struct oom_control *oc)
/* Check this allocation failure is caused by cpuset's wall function */
for_each_zone_zonelist_nodemask(zone, z, oc->zonelist,
- high_zoneidx, oc->nodemask)
+ highest_zoneidx, oc->nodemask)
if (!cpuset_zone_allowed(zone, oc->gfp_mask))
cpuset_limited = true;