[PATCH v2 2/5] arm64/mm: drop vmemmap_pmd helpers and use generic code
Will Deacon
will at kernel.org
Mon May 18 05:33:36 PDT 2026
On Sat, Apr 04, 2026 at 08:20:55PM +0800, Muchun Song wrote:
> The generic implementations now suffice; remove the arm64 copies.
>
> Signed-off-by: Muchun Song <songmuchun at bytedance.com>
> ---
> arch/arm64/mm/mmu.c | 14 --------------
> 1 file changed, 14 deletions(-)
>
> diff --git a/arch/arm64/mm/mmu.c b/arch/arm64/mm/mmu.c
> index ec1c6971a561..b87053452641 100644
> --- a/arch/arm64/mm/mmu.c
> +++ b/arch/arm64/mm/mmu.c
> @@ -1745,20 +1745,6 @@ static void free_empty_tables(unsigned long addr, unsigned long end,
> }
> #endif
>
> -void __meminit vmemmap_set_pmd(pmd_t *pmdp, void *p, int node,
> - unsigned long addr, unsigned long next)
> -{
> - pmd_set_huge(pmdp, __pa(p), __pgprot(PROT_SECT_NORMAL));
> -}
> -
> -int __meminit vmemmap_check_pmd(pmd_t *pmdp, int node,
> - unsigned long addr, unsigned long next)
> -{
> - vmemmap_verify((pte_t *)pmdp, node, addr, next);
> -
> - return pmd_sect(READ_ONCE(*pmdp));
> -}
I think this is fine:
Acked-by: Will Deacon <will at kernel.org>
but note that, since c25c4aa3f79a ("arm64: mm: Add PTE_DIRTY back to
PAGE_KERNEL* to fix kexec/hibernation"), I think that using PAGE_KERNEL
(like the generic code does in the first patch of this series) means
that this change isn't a no-op -- it means that the huge entries will
now be marked as dirty. That's possibly a bug fix (?)
Will
More information about the linux-arm-kernel
mailing list