Re: [PATCH v1] hugetlb: simplify remove_inode_hugepages() return type
From: Muchun Song
Date: Wed Feb 04 2026 - 01:07:44 EST
> On Feb 3, 2026, at 07:36, Jiaqi Yan <jiaqiyan@xxxxxxxxxx> wrote:
>
> When remove_inode_hugepages is introduced in
> commit c86272287bc6 ("hugetlb: create remove_inode_single_folio to remove single file folio")
> it used to return a boolean to indicate if it bailed out due to race with
> page faults. However, since the race is already solved by [1],
> remove_inode_hugepages() doesn't have any path to return false anymore.
>
> Simplify remove_inode_hugepages() return type to void, remove the
> unnecessary ret variable, and adjust the call site in
> remove_inode_hugepages(). No functional change in this commit.
>
> [1] https://lore.kernel.org/all/20220914221810.95771-10-mike.kravetz@xxxxxxxxxx
>
> Suggested-by: Jane Chu <jane.chu@xxxxxxxxxx>
> Signed-off-by: Jiaqi Yan <jiaqiyan@xxxxxxxxxx>
Reviewed-by: Muchun Song <muchun.song@xxxxxxxxx>