arm64: entry: Add fake CPU feature for unmapping the kernel at EL0
Allow explicit disabling of the entry trampoline on the kernel command line (kpti=off) by adding a fake CPU feature (ARM64_UNMAP_KERNEL_AT_EL0) that can be used to toggle the alternative sequences in our entry code and avoid use of the trampoline altogether if desired. This also allows us to make use of a static key in arm64_kernel_unmapped_at_el0(). Reviewed-by:Mark Rutland <mark.rutland@arm.com> Tested-by:
Laura Abbott <labbott@redhat.com> Tested-by:
Shanker Donthineni <shankerd@codeaurora.org> Signed-off-by:
Will Deacon <will.deacon@arm.com>
Showing
- arch/arm64/include/asm/cpucaps.h 2 additions, 1 deletionarch/arm64/include/asm/cpucaps.h
- arch/arm64/include/asm/mmu.h 2 additions, 1 deletionarch/arm64/include/asm/mmu.h
- arch/arm64/kernel/cpufeature.c 41 additions, 0 deletionsarch/arm64/kernel/cpufeature.c
- arch/arm64/kernel/entry.S 5 additions, 4 deletionsarch/arm64/kernel/entry.S
Please register or sign in to comment