Re: [PATCH] mm: memory-failure: remove unneeded page state check in shake_page()

From: Miaohe Lin
Date: Sun Jun 25 2023 - 21:43:54 EST


On 2023/6/26 3:50, Matthew Wilcox wrote:
> On Sun, Jun 25, 2023 at 07:34:30PM +0800, Miaohe Lin wrote:
>> Remove unneeded PageLRU(p) and is_free_buddy_page(p) check as slab caches
>> are not shrunk now. This check can be added back when a lightweight range
>> based shrinker is available.
>
> On further review, I think you've misunderstood the entire situation
> here and no patch should be applied.

Thanks for your review. I think you might misunderstood the patch. What I want
to do here is remove the unneeded if block:

if (PageLRU(p) || is_free_buddy_page(p))
return;

Because nothing is done after the check. So this check is useless and should be removed.
Thanks.