Thread (8 messages) 8 messages, 5 authors, 2025-06-12

Re: [PATCH v3] arm64: Restrict pagetable teardown to avoid false warning

From: Catalin Marinas <catalin.marinas@arm.com>
Date: 2025-06-10 16:37:59
Also in: lkml, stable

On Tue, May 27, 2025 at 01:56:33PM +0530, Dev Jain wrote:
Commit 9c006972c3fe removes the pxd_present() checks because the caller
checks pxd_present(). But, in case of vmap_try_huge_pud(), the caller only
checks pud_present(); pud_free_pmd_page() recurses on each pmd through
pmd_free_pte_page(), wherein the pmd may be none. Thus it is possible to
hit a warning in the latter, since pmd_none => !pmd_table(). Thus, add
a pmd_present() check in pud_free_pmd_page().

This problem was found by code inspection.

Fixes: 9c006972c3fe (arm64: mmu: drop pXd_present() checks from pXd_free_pYd_table())
Cc: <redacted>
Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help