]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: arm64: Bootstrap PSCI SMC handler in nVHE EL2
authorDavid Brazdil <dbrazdil@google.com>
Wed, 2 Dec 2020 18:41:12 +0000 (18:41 +0000)
committerMarc Zyngier <maz@kernel.org>
Fri, 4 Dec 2020 10:08:34 +0000 (10:08 +0000)
commit268e5ea47b295358937d6d3036dd6254a79c2cab
treef95c9cfefa430270e54dbe1717b91ff913e82dda
parenta13ad0e9a30d414ec26a46e7f53f9480d11606f2
KVM: arm64: Bootstrap PSCI SMC handler in nVHE EL2

Add a handler of PSCI SMCs in nVHE hyp code. The handler is initialized
with the version used by the host's PSCI driver and the function IDs it
was configured with. If the SMC function ID matches one of the
configured PSCI calls (for v0.1) or falls into the PSCI function ID
range (for v0.2+), the SMC is handled by the PSCI handler. For now, all
SMCs return PSCI_RET_NOT_SUPPORTED.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-17-dbrazdil@google.com
arch/arm64/include/asm/kvm_hyp.h
arch/arm64/kvm/arm.c
arch/arm64/kvm/hyp/include/nvhe/trap_handler.h [new file with mode: 0644]
arch/arm64/kvm/hyp/nvhe/Makefile
arch/arm64/kvm/hyp/nvhe/hyp-main.c
arch/arm64/kvm/hyp/nvhe/psci-relay.c [new file with mode: 0644]