]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: arm64: nVHE: Switch to hyp context for EL2
authorAndrew Scull <ascull@google.com>
Tue, 15 Sep 2020 10:46:36 +0000 (11:46 +0100)
committerMarc Zyngier <maz@kernel.org>
Tue, 15 Sep 2020 17:39:03 +0000 (18:39 +0100)
commit5d43fec826b8a22843e0e7a528e72a0f9d88bf61
tree327744162b7e9be685044a5ca25fb24914380c0c
parentf7a3d7e1244decea951ec712b3eb590ab4cad5c6
KVM: arm64: nVHE: Switch to hyp context for EL2

Save and restore the host context when switching to and from hyp. This
gives hyp its own context that the host will not see as a step towards a
full trust boundary between the two.

SP_EL0 and pointer authentication keys are currently shared between the
host and hyp so don't need to be switched yet.

Signed-off-by: Andrew Scull <ascull@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20200915104643.2543892-13-ascull@google.com
arch/arm64/kvm/hyp/include/hyp/switch.h
arch/arm64/kvm/hyp/nvhe/Makefile
arch/arm64/kvm/hyp/nvhe/host.S
arch/arm64/kvm/hyp/nvhe/hyp-main.c [new file with mode: 0644]