OSDN Git Service

arm64: cpufeature: Add CPU capability for AArch32 EL1 support
authorWill Deacon <will@kernel.org>
Tue, 21 Apr 2020 14:29:17 +0000 (15:29 +0100)
committerWill Deacon <will@kernel.org>
Tue, 28 Apr 2020 13:23:23 +0000 (14:23 +0100)
commit540f76d12c662d3da2ebdf0086ee289123fcd120
tree8dab996c565a7e539b613949c1d575ce42820711
parent0113340e6e83f8710b216f72b826499fc0151c29
arm64: cpufeature: Add CPU capability for AArch32 EL1 support

Although we emit a "SANITY CHECK" warning and taint the kernel if we
detect a CPU mismatch for AArch32 support at EL1, we still online the
CPU with disastrous consequences for any running 32-bit VMs.

Introduce a capability for AArch32 support at EL1 so that late onlining
of incompatible CPUs is forbidden.

Tested-by: Sai Prakash Ranjan <saiprakash.ranjan@codeaurora.org>
Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Acked-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20200421142922.18950-4-will@kernel.org
Signed-off-by: Will Deacon <will@kernel.org>
arch/arm64/include/asm/cpucaps.h
arch/arm64/include/asm/sysreg.h
arch/arm64/kernel/cpufeature.c
arch/arm64/kvm/reset.c