]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
arm64/mm: Change pgattr_change_is_safe() arguments as pteval_t
authorAnshuman Khandual <anshuman.khandual@arm.com>
Tue, 1 Oct 2024 04:58:04 +0000 (10:28 +0530)
committerCatalin Marinas <catalin.marinas@arm.com>
Wed, 16 Oct 2024 13:46:39 +0000 (14:46 +0100)
pgattr_change_is_safe() processes two distinct page table entries that just
happen to be 64 bits for all levels. This changes both arguments to reflect
the actual data type being processed in the function.

This change is important when moving to FEAT_D128 based 128 bit page tables
because it makes it simple to change the entry size in one place.

Cc: Will Deacon <will@kernel.org>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Ard Biesheuvel <ardb@kernel.org>
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-kernel@vger.kernel.org
Reviewed-by: Ryan Roberts <ryan.roberts@arm.com>
Signed-off-by: Anshuman Khandual <anshuman.khandual@arm.com>
Link: https://lore.kernel.org/r/20241001045804.1119881-1-anshuman.khandual@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm64/include/asm/pgtable.h
arch/arm64/mm/mmu.c

index c329ea061dc988a05d50931e24bd9b4389028f61..d56dbe5742d63089362730d01838dce86b7c68bf 100644 (file)
@@ -338,7 +338,7 @@ static inline pte_t __ptep_get(pte_t *ptep)
 }
 
 extern void __sync_icache_dcache(pte_t pteval);
-bool pgattr_change_is_safe(u64 old, u64 new);
+bool pgattr_change_is_safe(pteval_t old, pteval_t new);
 
 /*
  * PTE bits configuration in the presence of hardware Dirty Bit Management
index e55b02fbddc8f38fcef2def8249c4008285fce2e..c1b2d0dc3078fdf188b4804122ad0a12a90a7a37 100644 (file)
@@ -119,7 +119,7 @@ static phys_addr_t __init early_pgtable_alloc(int shift)
        return phys;
 }
 
-bool pgattr_change_is_safe(u64 old, u64 new)
+bool pgattr_change_is_safe(pteval_t old, pteval_t new)
 {
        /*
         * The following mapping attributes may be updated in live