[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y2+sbbirX11Vo+XM@cmpxchg.org>
Date: Sat, 12 Nov 2022 09:23:41 -0500
From: Johannes Weiner <hannes@...xchg.org>
To: Hongchen Zhang <zhanghongchen@...ngson.cn>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Mel Gorman <mgorman@...hsingularity.net>,
Hugh Dickins <hughd@...gle.com>,
Joonsoo Kim <iamjoonsoo.kim@....com>, linux-mm@...ck.org,
linux-kernel@...r.kernel.org, kernel-team@...com,
Yosry Ahmed <yosryahmed@...gle.com>
Subject: Re: [PATCH] mm: vmscan: fix extreme overreclaim and swap floods
On Tue, Sep 20, 2022 at 02:12:17PM +0800, Hongchen Zhang wrote:
> On 2022/8/3 am 12:28, Johannes Weiner wrote:
> > @@ -2988,8 +2988,6 @@ static void shrink_lruvec(struct lruvec *lruvec, struct scan_control *sc)
> > nr_scanned = targets[lru] - nr[lru];
> > nr[lru] = targets[lru] * (100 - percentage) / 100;
> > nr[lru] -= min(nr[lru], nr_scanned);
> We should not just remove the following line because kswapd may also call
> this function and there is no side effect to do scan adjust for kswapd,so it
> may be better to change like this:
> + if (current_is_kswapd())
> scan_adjusted = true;
> > -
> > - scan_adjusted = true
There is no scan_adjusted after this patch.
If you're saying that kswapd should set proportional_reclaim
unconditionally, then no, it should not. Proportional reclaim is not
safe at lower priority levels, as the changelog outlines in detail.
Powered by blists - more mailing lists