]> www.infradead.org Git - users/jedix/linux-maple.git/commit
fs/proc/task_mmu: hold PTL in pagemap_hugetlb_range and gather_hugetlb_stats
authorJinjiang Tu <tujinjiang@huawei.com>
Thu, 24 Jul 2025 09:09:57 +0000 (17:09 +0800)
committerAndrew Morton <akpm@linux-foundation.org>
Tue, 5 Aug 2025 20:38:39 +0000 (13:38 -0700)
commitaa5a10b070690225317ed4d85413d144abfff750
tree333eceec567ccfd9b4fccf3105acff8efed117ff
parent45d19b4b6c2d422771c29b83462d84afcbb33f01
fs/proc/task_mmu: hold PTL in pagemap_hugetlb_range and gather_hugetlb_stats

Hold PTL in pagemap_hugetlb_range() and gather_hugetlb_stats() to avoid
operating on stale page, as pagemap_pmd_range() and gather_pte_stats()
have done.

Link: https://lkml.kernel.org/r/20250724090958.455887-3-tujinjiang@huawei.com
Signed-off-by: Jinjiang Tu <tujinjiang@huawei.com>
Acked-by: David Hildenbrand <david@redhat.com>
Cc: Andrei Vagin <avagin@gmail.com>
Cc: Andrii Nakryiko <andrii@kernel.org>
Cc: Baolin Wang <baolin.wang@linux.alibaba.com>
Cc: Brahmajit Das <brahmajit.xyz@gmail.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Christophe Leroy <christophe.leroy@csgroup.eu>
Cc: David Rientjes <rientjes@google.com>
Cc: Dev Jain <dev.jain@arm.com>
Cc: Hugh Dickins <hughd@google.com>
Cc: Joern Engel <joern@logfs.org>
Cc: Kefeng Wang <wangkefeng.wang@huawei.com>
Cc: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Ryan Roberts <ryan.roberts@arm.com>
Cc: Thiago Jung Bauermann <thiago.bauermann@linaro.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
fs/proc/task_mmu.c