[PATCH v6 2/4] armv8: mmu: teach the pagetable dumper to show explicit FAULT maps
Casey Connolly
casey.connolly at linaro.org
Mon Jun 8 19:13:49 CEST 2026
When a region is explicitly unmapped (like with
mmu_change_region_attr(.... PTE_TYPE_FAULT)) the address translation
still remains but won't be used since the region is marked invalid.
Print these regions when we dump the pagetable to help with debugging.
Signed-off-by: Casey Connolly <casey.connolly at linaro.org>
---
arch/arm/cpu/armv8/cache_v8.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/arm/cpu/armv8/cache_v8.c b/arch/arm/cpu/armv8/cache_v8.c
index f07204ed2fad..91c55591a1d9 100644
--- a/arch/arm/cpu/armv8/cache_v8.c
+++ b/arch/arm/cpu/armv8/cache_v8.c
@@ -533,9 +533,9 @@ static void __pagetable_walk(u64 addr, u64 tcr, int level, pte_walker_cb_t cb, v
if (exit)
return;
- if (pte_type(&pte) == PTE_TYPE_FAULT)
+ if (!pte)
continue;
attrs = pte & ALL_ATTRS;
/* If we're currently inside a block or set of pages */
@@ -572,9 +572,9 @@ static void __pagetable_walk(u64 addr, u64 tcr, int level, pte_walker_cb_t cb, v
/* Go down a level */
__pagetable_walk(_addr, tcr, level + 1, cb, priv);
state[level] = WALKER_STATE_START;
- } else if (pte_type(&pte) == PTE_TYPE_BLOCK || pte_type(&pte) == PTE_TYPE_PAGE) {
+ } else {
/* We foud a block or page, start walking */
entry_start = pte;
state[level] = WALKER_STATE_REGION;
}
--
2.53.0
More information about the U-Boot
mailing list