lkml.org 
[lkml]   [2022]   [Dec]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 1/2] hugetlb: really allocate vma lock for all sharable vmas
From
Date
On 2022/12/13 7:50, Mike Kravetz wrote:
> Commit bbff39cc6cbc ("hugetlb: allocate vma lock for all sharable vmas")
> removed the pmd sharable checks in the vma lock helper routines.
> However, it left the functional version of helper routines behind #ifdef
> CONFIG_ARCH_WANT_HUGE_PMD_SHARE. Therefore, the vma lock is not being

Oh, we missed !CONFIG_ARCH_WANT_HUGE_PMD_SHARE case in the previous review. :(

> used for sharable vmas on architectures that do not support pmd sharing.
> On these architectures, a potential fault/truncation race is exposed
> that could leave pages in a hugetlb file past i_size until the file is
> removed.
>
> Move the functional vma lock helpers outside the ifdef, and remove the
> non-functional stubs. Since the vma lock is not just for pmd sharing,
> rename the routine __vma_shareable_flags_pmd.
>
> Fixes: bbff39cc6cbc ("hugetlb: allocate vma lock for all sharable vmas")
> Signed-off-by: Mike Kravetz <mike.kravetz@oracle.com>

Thanks for fixing. This patch looks good to me. Thanks.

Reviewed-by: Miaohe Lin <linmiaohe@huawei.com>

Thanks,
Miaohe Lin

\
 
 \ /
  Last update: 2022-12-17 03:00    [W:0.077 / U:1.168 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site