[PATCH 2/2] arm64: add software pagetable walker

Tom Rini trini at konsulko.com
Fri Jun 7 19:00:50 CEST 2024


On Fri, Jun 07, 2024 at 06:51:20PM +0200, Caleb Connolly wrote:

> Add a basic software implementation of the ARM64 pagetable walker. This
> can be used for debugging U-Boot's pagetable, as well as dumping the
> pagetable from the previous bootloader stage if it used one (by reading
> out the ttbr address).
> 
> One can either call dump_pagetable() to print the pagetable to the
> console with the default formatter, or implement their own pagetable
> handler using walke_pagetable() with a custom pte_walker_cb_t callback.
> 
> Signed-off-by: Caleb Connolly <caleb.connolly at linaro.org>
> ---
>  arch/arm/cpu/armv8/cache_v8.c    | 202 +++++++++++++++++++++++++++++++++++++++
>  arch/arm/include/asm/armv8/mmu.h |  55 +++++++++++
>  2 files changed, 257 insertions(+)

So, I assume that by default, all of this gets discarded as unused code
and that's why it's not behind a Kconfig. Next, please add something
under maybe doc/arch/ or doc/develop (I'm honestly not sure which is
best) that documents all of this. Thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20240607/dbb006ef/attachment.sig>


More information about the U-Boot mailing list