Re: [PATCH bpf-next v11 1/2] mm/bpf: Add bpf_proactive_reclaim kfunc

From: Barry Song

Date: Wed Sep 16 2026 - 17:49:13 EST


On Tue, Sep 15, 2026 at 8:30 PM Hui Zhu <hui.zhu@xxxxxxxxx> wrote:
[...]
> /**
> @@ -159,6 +161,47 @@ __bpf_kfunc void bpf_mem_cgroup_flush_stats(struct mem_cgroup *memcg)
> mem_cgroup_flush_stats(memcg);
> }
>
> +/**
> + * bpf_proactive_reclaim - proactively reclaim memory from a memory cgroup
> + * @memcg: the target memory cgroup to reclaim from
> + * @size: the amount of memory to reclaim, in bytes, clamped to
> + * MEMCG_CHARGE_BATCH
> + * @swappiness: the reclaim swappiness, in the range [MIN_SWAPPINESS,
> + * SWAPPINESS_ANON_ONLY], or -1 to use the memcg's own

I assume you missed the word "swappiness" here: "use the memcg's own
swappiness".

Best Regards
Barry