]> www.infradead.org Git - users/jedix/linux-maple.git/commit
arm64: ptdump: Don't override the level when operating on the stage-2 tables
authorSebastian Ene <sebastianene@google.com>
Mon, 9 Sep 2024 12:47:20 +0000 (12:47 +0000)
committerMarc Zyngier <maz@kernel.org>
Tue, 10 Sep 2024 20:32:51 +0000 (21:32 +0100)
commit79c4c7284f92d5e780c8532c343ca2cacfaf5125
tree9228125477894769c1e07c42590bc04ff8844fb5
parent9182301a7bd2564fb050ade9820333c8b1adfcc2
arm64: ptdump: Don't override the level when operating on the stage-2 tables

Ptdump uses the init_mm structure directly to dump the kernel
pagetables. When ptdump is called on the stage-2 pagetables, this mm
argument is not used. Prevent the level from being overwritten by
checking the argument against NULL.

Signed-off-by: Sebastian Ene <sebastianene@google.com>
Acked-by: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20240909124721.1672199-5-sebastianene@google.com
Signed-off-by: Marc Zyngier <maz@kernel.org>
arch/arm64/mm/ptdump.c