Re: [PATCH] mm/vmscan: reclaim every zone in per-node proactive reclaim
From: Gregory Price (Meta)
Date: Tue Oct 20 2026 - 15:59:06 EST
On 2026-10-20 09:49 +0200, Michal Hocko wrote:
>
> Would it make more sense to
> diff --git a/mm/vmscan.c b/mm/vmscan.c
> index f11491ee9ed5..e07db9514e59 100644
> --- a/mm/vmscan.c
> +++ b/mm/vmscan.c
> @@ -7963,7 +7963,7 @@ int user_proactive_reclaim(char *buf,
> int swappiness = -1;
> char *old_buf, *start;
> substring_t args[MAX_OPT_ARGS];
> - gfp_t gfp_mask = GFP_KERNEL;
> + gfp_t gfp_mask = GFP_HIGHUSER_MOVABLE;
>
> if (!buf || (!memcg && !pgdat) || (memcg && pgdat))
> return -EINVAL;
>
> That would take care of try_to_free_mem_cgroup_pages too.
funny enough, try_to_free_mem_cgroup_pages does what my patch does:
struct scan_control sc = {
.reclaim_idx = MAX_NR_ZONES - 1,
now, whether the gfp_mask should be GFP_KERNEL, that's a different
question i think.
(tl;dr i think my patch is still correct)
~Gregory
--
Gregory Price (Meta) <gourry@xxxxxxxxxx>