Re: [PATCH 0/5] Fix incorrect access of hugetlb pte entries

From: Dev Jain

Date: Fri Jun 26 2026 - 00:10:09 EST




On 25/06/26 7:29 pm, Zi Yan wrote:
> On Thu Jun 25, 2026 at 7:29 AM EDT, Dev Jain wrote:
>> There are various places which use ptep_get() to get the pte entry
>> corresponding to a hugetlb folio. Some arches have special handling
>
> I think it is better to mention s390 as a concrete example.

Sure. In case there is no v2, requesting Andrew to change
"Some arches have special handling" to "Some arches like s390 have
special handling".

>
>> to compute the pteval, so they provide huge_ptep_get(). Use this
>> helper consistently.
>>
>> Dev Jain (5):
>> mm/rmap: use huge_ptep_get() in try_to_unmap_one()
>> mm/rmap: use huge_ptep_get() in try_to_migrate_one()
>> mm/migrate: use huge_ptep_get() in remove_migration_pte()
>> mm/page_vma_mapped: use huge_ptep_get() for hugetlb
>> mm/mprotect: use huge_ptep_get() for hugetlb
>>
>> include/linux/hugetlb.h | 3 +++
>> mm/migrate.c | 6 +++++-
>> mm/mprotect.c | 8 +++++++-
>> mm/page_vma_mapped.c | 8 +++++++-
>> mm/rmap.c | 32 ++++++++++++++++++++------------
>> 5 files changed, 42 insertions(+), 15 deletions(-)
>
>
>
>