From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id F1AF2C369AB for ; Tue, 22 Apr 2025 01:26:25 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 272166B000A; Mon, 21 Apr 2025 21:26:24 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 226466B000C; Mon, 21 Apr 2025 21:26:24 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id ECDBE6B000D; Mon, 21 Apr 2025 21:26:23 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0014.hostedemail.com [216.40.44.14]) by kanga.kvack.org (Postfix) with ESMTP id CCFA36B000A for ; Mon, 21 Apr 2025 21:26:23 -0400 (EDT) Received: from smtpin01.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id E543F81589 for ; Tue, 22 Apr 2025 01:26:23 +0000 (UTC) X-FDA: 83359939446.01.8F3F11C Received: from mail-qv1-f52.google.com (mail-qv1-f52.google.com [209.85.219.52]) by imf04.hostedemail.com (Postfix) with ESMTP id 303484000B for ; Tue, 22 Apr 2025 01:26:22 +0000 (UTC) Authentication-Results: imf04.hostedemail.com; dkim=pass header.d=gourry.net header.s=google header.b=OTPqXC1Z; dmarc=none; spf=pass (imf04.hostedemail.com: domain of gourry@gourry.net designates 209.85.219.52 as permitted sender) smtp.mailfrom=gourry@gourry.net ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1745285182; a=rsa-sha256; cv=none; b=eDKLZ9HmQ11Um1iA898+gX12++lJWwzGmnKo/8zuClzTcGQoeCwATxg54HximU69cqPDA/ KOj23ovJCO9mu+crfdP4sJJ0UOfHnmkYVBvLtPCSCVDfoQNMfDvZ9Md7NXST+PODK7PUKj EU4IicY/nveJjwcJ6Mjs1oSEltJcSgk= ARC-Authentication-Results: i=1; imf04.hostedemail.com; dkim=pass header.d=gourry.net header.s=google header.b=OTPqXC1Z; dmarc=none; spf=pass (imf04.hostedemail.com: domain of gourry@gourry.net designates 209.85.219.52 as permitted sender) smtp.mailfrom=gourry@gourry.net ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1745285182; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=9Kle4Lqt4WBt6giVl/+yUtlyI+tb9qWSFjEQjFngXB0=; b=UzTjtf00p67WlJ/csaZue9hHkI/MBS7ok/oP5FU3vxssD3I4/0p7u4m/JCDKVUeHnh7wbl MXqcjp5iRV3KoikOn+9BueVKsC9hWL8k8UvpeRZXT9rspAIusJK8AXZrDRJ7HYUZcr5cIo UdhJZ5q8UfStQ8WjaJFxD3Z2xFd7J+U= Received: by mail-qv1-f52.google.com with SMTP id 6a1803df08f44-6f0ad744811so30268096d6.1 for ; Mon, 21 Apr 2025 18:26:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gourry.net; s=google; t=1745285181; x=1745889981; darn=kvack.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=9Kle4Lqt4WBt6giVl/+yUtlyI+tb9qWSFjEQjFngXB0=; b=OTPqXC1ZkuIMkxmcqFkkb2j/zUdxNN34grRov1/SYTpjrrM9gK9fuYb3i/6cib5JPm X6xv5/hX1tdjpWHCMg3X/OWuxyvi/DwubISs2XrA++ZVVanQ3UM8K6RZ+iJrwhYM3EnT fj96V1OZgE5OO38BS2YgRRPSXPoUHHDyUZoWQc5uE55l4nCADgtynShmqohfYChJfv3n GTv9/Su9C+DCcOvNCYlXq2tyVew7Gi0Ku9O6rJW8xLydss+LpkKdl4LGC3tmLxG6a9lw 5UxLHlX8CfErfREeBk4nrJ97pcUxsGNg3XXeJSfyD/ORbsjPyzD8+CyH+l8cF5xVs9Ow UgZw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1745285181; x=1745889981; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=9Kle4Lqt4WBt6giVl/+yUtlyI+tb9qWSFjEQjFngXB0=; b=qMylSy6JxIajBGKJGDU6LK46Vg1pwGXcWYqHyi5qPj1KDfa7bvQp6qw1x7z2Vj2EUv x2V/ZLdfblquGi1YQNMNQCAaUTbmYF45fK9zahnhNdyzwpYDRW0AvJ9ytU+HBpBPwbs5 0AHaaOw33IdM8cRCGMh8YqHIzz4bVRpkV/hzcleUsNbhBbTybWcAaL9fYYjsVKKmSfqh A4pCBE4xDEDv/TUekM31p066NhorBN4LLWyLDF8wr9fGQ6y+XjRiVe/zTkSNznJNAaDt ABYy4b4oMgKsCnkh2z9NzuGUT5L56ycME7vuThUmsjFLoOiX9lhW14vR/9q9ZsQ433mP Y1RQ== X-Gm-Message-State: AOJu0YzGDswlRYewAhpit7OLv0wyMOqNUl6HMcMKnZD/CuLrQs2DG3m8 LGnXex2wB/InO1qkbRKoPkr3P92jMVcP8+RhVbKe77esXvR+O7OHBrIetIPBFHWuN12Mrnfur5Q o X-Gm-Gg: ASbGncvYop9HWXAsL5UsV8sgWN2MlXj3brBzpXdTsnjBIAFKlooo3q8TI4/ZtkGSlR/ Lxnn2XaD8SXGPm86tsi44SQft7xCWxvlpRoezypftd+jJcB4cwktxyO+qrMk0W+kH1umbDQh+9n Ca5HAaIhNfWUORKiyB74ySD/3oApvg3GEtkJF4/eaZqUATdcKSTxakuC9OqqtJKL3dSukkQ3SLp ZuNQ/BT0IU2BXjwXHsHfmP+G2t+eem2u9M6eglq+Gjp5+rICbToWQBQa0bXGsgnGWvOsScYTkEr bLAZnztgj9CxpzvKXuYOTND0Q6q6Cp6fc2eaCf8lAzxh8v0W50e9pQ1mYo02xn9K4Wl6eNKeuTp TgNqvHR1JlcGwqcW+0WnfkaBV0tKUvZFAEeFxWu0= X-Google-Smtp-Source: AGHT+IG6HxcdwaS4DYHDMOqX5ZLpYXYsTbmi3+FGkCgYV4wxqXoEUZtvFG5cMXhmSwORfqHFe+7drA== X-Received: by 2002:a05:6214:2484:b0:6f2:b551:a65 with SMTP id 6a1803df08f44-6f2c4674ffcmr281778536d6.38.1745285181142; Mon, 21 Apr 2025 18:26:21 -0700 (PDT) Received: from gourry-fedora-PF4VCD3F.lan (pool-173-79-56-208.washdc.fios.verizon.net. [173.79.56.208]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-6f2c2c00d78sm50985746d6.79.2025.04.21.18.26.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 21 Apr 2025 18:26:20 -0700 (PDT) From: Gregory Price To: linux-mm@kvack.org Cc: cgroups@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-team@meta.com, longman@redhat.com, hannes@cmpxchg.org, mhocko@kernel.org, roman.gushchin@linux.dev, shakeel.butt@linux.dev, muchun.song@linux.dev, tj@kernel.org, mkoutny@suse.com, akpm@linux-foundation.org Subject: [PATCH v4 2/2] vmscan,cgroup: apply mems_effective to reclaim Date: Mon, 21 Apr 2025 21:26:15 -0400 Message-ID: <20250422012616.1883287-3-gourry@gourry.net> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250422012616.1883287-1-gourry@gourry.net> References: <20250422012616.1883287-1-gourry@gourry.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: 303484000B X-Stat-Signature: 1rdc6jdwoon3k57aph7urnrxyy6afybd X-Rspam-User: X-HE-Tag: 1745285182-679909 X-HE-Meta: U2FsdGVkX1+q9crbexyAXAX10YQuzpro5VVBF3OqM9ZoCjwi1dVNwzHKfM/jPOZdueDmpkYbvWv2A33/MFlFtQhtsukniZtjCtikNgdhFr15Sf3pbo9LSuIdlxO21S0Ft+qC3uyJ/l0sAxT8g3LuKkG7Ld9ADkjOt2Up6sHCY209BDjEP5LI85bShzEmDtE4AeBhRMfu/OSVNyhf/n1J8JctA2n7ICQBLjcXVnL3/eE8vlLd2k9urS3p8Z5AEufYxjRwFTYuGFHk494BXaoN/8DUMf4Q4DPCJK0Coezm7iOtoaLHMnIpyNBuoPMOqMlWyN5a4tCPXXY2pbN93ZpsMhtKkZ16lLlqTa0CcrymhkBqxzXBkJwX6kpoytonKS/IzEZn2iJ3ZHrdqxcT+sVbCu/TjquPnUAXL9m5i4o22Vr9xzeLsiD2YgT4RWqHGWMWfywLjxRY8TzJNoLwHhZLF4wxzOafRWYHgdJKDtedGKHfyvFKqWqWs932eEKmiCyIINj9NVWbIkABt+Jp6OLDKwjnQ8Mu/C7R+ziU9VH4bnOVXs/V08Clju9rO5/6R0o7cm9bZ/EzYjXlRn95geWhyMAYt3fcOSpLoP5VuKAUoDAyMV0BKPngzVgxMmSh1nC50MIT9DVENUCqZF4tNRM+XCy5bWlRQOMjtIeq1jQ81jUARYlyLVjDEjVwVT/oavk1Moscypz6UfVRITt9VyeuIhrlJPDylvOYNP/Xsbx+HOmJ+Iuk26vgAoG2OL6rk5kphptJnX/sg6xh322G1ub7CdWftueg4Ae3PCTwuBoCGAWKMgNON0JuAHm++9J3QxNqzD5X8h0VIOpDRe4M1c+MBYLOJoj+OlwWDkqm8qUQhKGW8bp3F6bzd1vS3ttEdo0OFDV6IJFz9RMs44eoKjflL/apyaXMIR036YG4HL7+3kfAK15WD2GNAafqrAeo61keOP6zvUY+g1OSc+LQIv9 qVPcc/54 EfqccCBEiZqnLh3qxPfjXao+AlOeymRxse8It9ava2l37qBH4V+meJlTQPNeWP0eFR4smEKWZM2Af009N3nneYkV2iyua2xuFi+ZFRX+wsVYmTcwDSn4sEf1NQ9yYGcspWitrxusJgtx4P6kzJ+Casd3Fnr+bH/f93ijDtXQeMZO7TYFIUTTnXr7AMrQn0wKJY1HZQk8xzIJT4Q7S61+/CHQK/EVB5HZ/Yu3s1EyCnuvWtJuTpmcA/Wnb9uy+9O9nG3pWC5AlfbjrVEjg6tLtsHsOiyk4bfuioNUYVJGuVwCEZOJprZz+/UT9Bdjdm1u7TzEkFmHF11Vy/KL10x639OMWjYaxd9Rq07sDQwUPAjhpF7NC9bMnOa3JJw== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: It is possible for a reclaimer to cause demotions of an lruvec belonging to a cgroup with cpuset.mems set to exclude some nodes. Attempt to apply this limitation based on the lruvec's memcg and prevent demotion. Notably, this may still allow demotion of shared libraries or any memory first instantiated in another cgroup. This means cpusets still cannot cannot guarantee complete isolation when demotion is enabled, and the docs have been updated to reflect this. This is useful for isolating workloads on a multi-tenant system from certain classes of memory more consistently - with the noted exceptions. Acked-by: Tejun Heo Signed-off-by: Gregory Price --- .../ABI/testing/sysfs-kernel-mm-numa | 16 +++++--- include/linux/cpuset.h | 5 +++ include/linux/memcontrol.h | 6 +++ kernel/cgroup/cpuset.c | 26 ++++++++++++ mm/memcontrol.c | 6 +++ mm/vmscan.c | 41 +++++++++++-------- 6 files changed, 78 insertions(+), 22 deletions(-) diff --git a/Documentation/ABI/testing/sysfs-kernel-mm-numa b/Documentation/ABI/testing/sysfs-kernel-mm-numa index 77e559d4ed80..90e375ff54cb 100644 --- a/Documentation/ABI/testing/sysfs-kernel-mm-numa +++ b/Documentation/ABI/testing/sysfs-kernel-mm-numa @@ -16,9 +16,13 @@ Description: Enable/disable demoting pages during reclaim Allowing page migration during reclaim enables these systems to migrate pages from fast tiers to slow tiers when the fast tier is under pressure. This migration - is performed before swap. It may move data to a NUMA - node that does not fall into the cpuset of the - allocating process which might be construed to violate - the guarantees of cpusets. This should not be enabled - on systems which need strict cpuset location - guarantees. + is performed before swap if an eligible numa node is + present in cpuset.mems for the cgroup (or if cpuset v1 + is being used). If cpusets.mems changes at runtime, it + may move data to a NUMA node that does not fall into the + cpuset of the new cpusets.mems, which might be construed + to violate the guarantees of cpusets. Shared memory, + such as libraries, owned by another cgroup may still be + demoted and result in memory use on a node not present + in cpusets.mem. This should not be enabled on systems + which need strict cpuset location guarantees. diff --git a/include/linux/cpuset.h b/include/linux/cpuset.h index 893a4c340d48..5255e3fdbf62 100644 --- a/include/linux/cpuset.h +++ b/include/linux/cpuset.h @@ -171,6 +171,7 @@ static inline void set_mems_allowed(nodemask_t nodemask) task_unlock(current); } +extern bool cpuset_node_allowed(struct cgroup *cgroup, int nid); #else /* !CONFIG_CPUSETS */ static inline bool cpusets_enabled(void) { return false; } @@ -282,6 +283,10 @@ static inline bool read_mems_allowed_retry(unsigned int seq) return false; } +static inline bool cpuset_node_allowed(struct cgroup *cgroup, int nid) +{ + return true; +} #endif /* !CONFIG_CPUSETS */ #endif /* _LINUX_CPUSET_H */ diff --git a/include/linux/memcontrol.h b/include/linux/memcontrol.h index 53364526d877..a6c4e3faf721 100644 --- a/include/linux/memcontrol.h +++ b/include/linux/memcontrol.h @@ -1736,6 +1736,8 @@ static inline void count_objcg_events(struct obj_cgroup *objcg, rcu_read_unlock(); } +bool mem_cgroup_node_allowed(struct mem_cgroup *memcg, int nid); + #else static inline bool mem_cgroup_kmem_disabled(void) { @@ -1793,6 +1795,10 @@ static inline void count_objcg_events(struct obj_cgroup *objcg, { } +static inline bool mem_cgroup_node_allowed(struct mem_cgroup *memcg, int nid) +{ + return true; +} #endif /* CONFIG_MEMCG */ #if defined(CONFIG_MEMCG) && defined(CONFIG_ZSWAP) diff --git a/kernel/cgroup/cpuset.c b/kernel/cgroup/cpuset.c index f8e6a9b642cb..c52348bfd5db 100644 --- a/kernel/cgroup/cpuset.c +++ b/kernel/cgroup/cpuset.c @@ -4163,6 +4163,32 @@ bool cpuset_current_node_allowed(int node, gfp_t gfp_mask) return allowed; } +bool cpuset_node_allowed(struct cgroup *cgroup, int nid) +{ + struct cgroup_subsys_state *css; + struct cpuset *cs; + bool allowed; + + /* + * In v1, mem_cgroup and cpuset are unlikely in the same hierarchy + * and mems_allowed is likely to be empty even if we could get to it, + * so return true to avoid taking a global lock on the empty check. + */ + if (!cpuset_v2()) + return true; + + css = cgroup_get_e_css(cgroup, &cpuset_cgrp_subsys); + if (!css) + return true; + + cs = container_of(css, struct cpuset, css); + rcu_read_lock(); + allowed = node_isset(nid, cs->effective_mems); + rcu_read_unlock(); + css_put(css); + return allowed; +} + /** * cpuset_spread_node() - On which node to begin search for a page * @rotor: round robin rotor diff --git a/mm/memcontrol.c b/mm/memcontrol.c index 40c07b8699ae..2f61d0060fd1 100644 --- a/mm/memcontrol.c +++ b/mm/memcontrol.c @@ -29,6 +29,7 @@ #include #include #include +#include #include #include #include @@ -5437,3 +5438,8 @@ static int __init mem_cgroup_swap_init(void) subsys_initcall(mem_cgroup_swap_init); #endif /* CONFIG_SWAP */ + +bool mem_cgroup_node_allowed(struct mem_cgroup *memcg, int nid) +{ + return memcg ? cpuset_node_allowed(memcg->css.cgroup, nid) : true; +} diff --git a/mm/vmscan.c b/mm/vmscan.c index 2b2ab386cab5..32a7ce421e42 100644 --- a/mm/vmscan.c +++ b/mm/vmscan.c @@ -342,16 +342,22 @@ static void flush_reclaim_state(struct scan_control *sc) } } -static bool can_demote(int nid, struct scan_control *sc) +static bool can_demote(int nid, struct scan_control *sc, + struct mem_cgroup *memcg) { + int demotion_nid; + if (!numa_demotion_enabled) return false; if (sc && sc->no_demotion) return false; - if (next_demotion_node(nid) == NUMA_NO_NODE) + + demotion_nid = next_demotion_node(nid); + if (demotion_nid == NUMA_NO_NODE) return false; - return true; + /* If demotion node isn't in the cgroup's mems_allowed, fall back */ + return mem_cgroup_node_allowed(memcg, demotion_nid); } static inline bool can_reclaim_anon_pages(struct mem_cgroup *memcg, @@ -376,7 +382,7 @@ static inline bool can_reclaim_anon_pages(struct mem_cgroup *memcg, * * Can it be reclaimed from this node via demotion? */ - return can_demote(nid, sc); + return can_demote(nid, sc, memcg); } /* @@ -1096,7 +1102,8 @@ static bool may_enter_fs(struct folio *folio, gfp_t gfp_mask) */ static unsigned int shrink_folio_list(struct list_head *folio_list, struct pglist_data *pgdat, struct scan_control *sc, - struct reclaim_stat *stat, bool ignore_references) + struct reclaim_stat *stat, bool ignore_references, + struct mem_cgroup *memcg) { struct folio_batch free_folios; LIST_HEAD(ret_folios); @@ -1109,7 +1116,7 @@ static unsigned int shrink_folio_list(struct list_head *folio_list, folio_batch_init(&free_folios); memset(stat, 0, sizeof(*stat)); cond_resched(); - do_demote_pass = can_demote(pgdat->node_id, sc); + do_demote_pass = can_demote(pgdat->node_id, sc, memcg); retry: while (!list_empty(folio_list)) { @@ -1658,7 +1665,7 @@ unsigned int reclaim_clean_pages_from_list(struct zone *zone, */ noreclaim_flag = memalloc_noreclaim_save(); nr_reclaimed = shrink_folio_list(&clean_folios, zone->zone_pgdat, &sc, - &stat, true); + &stat, true, NULL); memalloc_noreclaim_restore(noreclaim_flag); list_splice(&clean_folios, folio_list); @@ -2031,7 +2038,8 @@ static unsigned long shrink_inactive_list(unsigned long nr_to_scan, if (nr_taken == 0) return 0; - nr_reclaimed = shrink_folio_list(&folio_list, pgdat, sc, &stat, false); + nr_reclaimed = shrink_folio_list(&folio_list, pgdat, sc, &stat, false, + lruvec_memcg(lruvec)); spin_lock_irq(&lruvec->lru_lock); move_folios_to_lru(lruvec, &folio_list); @@ -2214,7 +2222,7 @@ static unsigned int reclaim_folio_list(struct list_head *folio_list, .no_demotion = 1, }; - nr_reclaimed = shrink_folio_list(folio_list, pgdat, &sc, &stat, true); + nr_reclaimed = shrink_folio_list(folio_list, pgdat, &sc, &stat, true, NULL); while (!list_empty(folio_list)) { folio = lru_to_folio(folio_list); list_del(&folio->lru); @@ -2646,7 +2654,7 @@ static void get_scan_count(struct lruvec *lruvec, struct scan_control *sc, * Anonymous LRU management is a waste if there is * ultimately no way to reclaim the memory. */ -static bool can_age_anon_pages(struct pglist_data *pgdat, +static bool can_age_anon_pages(struct lruvec *lruvec, struct scan_control *sc) { /* Aging the anon LRU is valuable if swap is present: */ @@ -2654,7 +2662,8 @@ static bool can_age_anon_pages(struct pglist_data *pgdat, return true; /* Also valuable if anon pages can be demoted: */ - return can_demote(pgdat->node_id, sc); + return can_demote(lruvec_pgdat(lruvec)->node_id, sc, + lruvec_memcg(lruvec)); } #ifdef CONFIG_LRU_GEN @@ -2732,7 +2741,7 @@ static int get_swappiness(struct lruvec *lruvec, struct scan_control *sc) if (!sc->may_swap) return 0; - if (!can_demote(pgdat->node_id, sc) && + if (!can_demote(pgdat->node_id, sc, memcg) && mem_cgroup_get_nr_swap_pages(memcg) < MIN_LRU_BATCH) return 0; @@ -4695,7 +4704,7 @@ static int evict_folios(struct lruvec *lruvec, struct scan_control *sc, int swap if (list_empty(&list)) return scanned; retry: - reclaimed = shrink_folio_list(&list, pgdat, sc, &stat, false); + reclaimed = shrink_folio_list(&list, pgdat, sc, &stat, false, memcg); sc->nr.unqueued_dirty += stat.nr_unqueued_dirty; sc->nr_reclaimed += reclaimed; trace_mm_vmscan_lru_shrink_inactive(pgdat->node_id, @@ -5850,7 +5859,7 @@ static void shrink_lruvec(struct lruvec *lruvec, struct scan_control *sc) * Even if we did not try to evict anon pages at all, we want to * rebalance the anon lru active/inactive ratio. */ - if (can_age_anon_pages(lruvec_pgdat(lruvec), sc) && + if (can_age_anon_pages(lruvec, sc) && inactive_is_low(lruvec, LRU_INACTIVE_ANON)) shrink_active_list(SWAP_CLUSTER_MAX, lruvec, sc, LRU_ACTIVE_ANON); @@ -6681,10 +6690,10 @@ static void kswapd_age_node(struct pglist_data *pgdat, struct scan_control *sc) return; } - if (!can_age_anon_pages(pgdat, sc)) + lruvec = mem_cgroup_lruvec(NULL, pgdat); + if (!can_age_anon_pages(lruvec, sc)) return; - lruvec = mem_cgroup_lruvec(NULL, pgdat); if (!inactive_is_low(lruvec, LRU_INACTIVE_ANON)) return; -- 2.49.0