riscv: Add support to dump the kernel page tables
In a similar manner to arm64, x86, powerpc, etc., it can traverse all page tables, and dump the page table layout with the memory types and permissions. Add a debugfs file at /sys/kernel/debug/kernel_page_tables to export the page table layout to userspace. Signed-off-by: NZong Li <zong.li@sifive.com> Tested-by: NAlexandre Ghiti <alex@ghiti.fr> Signed-off-by: NPalmer Dabbelt <palmerdabbelt@google.com>
Showing
arch/riscv/include/asm/ptdump.h
0 → 100644
arch/riscv/mm/ptdump.c
0 → 100644
想要评论请 注册 或 登录