Re: [PATCH v8 02/10] powerpc/8xx: add pte_set_huge()
flat view
From: Wen Jiang <hidden>
Date: 2026-09-18 08:20:51
Also in:
linux-mm, linuxppc-dev, lkml
On Fri, 18 Sept 2026 at 07:28, Barry Song [off-list ref] wrote:
On Thu, Sep 17, 2026 at 1:30 PM Wen Jiang [off-list ref] wrote:quoted
From: Wen Jiang <redacted> vmap installs PTE-level block mappings (SZ_16K/SZ_512K on powerpc/8xx) by reusing set_huge_pte_at(), a HugeTLB helper gated by CONFIG_HUGETLB_PAGE. This makes the feature silently unavailable on CONFIG_HUGETLB_PAGE=n kernels and couples mm/vmalloc.c to HugeTLB internals it does not otherwise need. Add pte_set_huge() to powerpc/8xx, next to the existing pmd_clear_huge()/pud_clear_huge() in mm/nohash/8xx.c. It builds the huge PTE and writes it into the backing cells directly, without going through set_huge_pte_at(), so it does not depend on CONFIG_HUGETLB_PAGE. No pte_clear_huge() is needed: 8xx does not implement arch_vmap_pte_range_unmap_size(), so the vmap unmap path never takes the block-mapping branch.I assume you mean the block-unmapping (or PTE-clearing) branch. Please make this clear in the changelog.
Sure. Will fix it. Thanks, Wen
quoted
In practice PPC_8xx selects HUGETLBFS unconditionally, so CONFIG_HUGETLB_PAGE=n does not occur there today; this is a decoupling cleanup rather than a new configuration. There is no caller yet: mm/vmalloc.c is converted later in this series, once the generic fallbacks are in place. Signed-off-by: Wen Jiang <redacted> ---BTW, this patch applies cleanly to the mm-new branch. Best Regards Barry