]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: arm64: Make kvm_condition_valid32() accessible from EL2
authorMarc Zyngier <marc.zyngier@arm.com>
Fri, 9 Jun 2017 11:49:32 +0000 (12:49 +0100)
committerMarc Zyngier <marc.zyngier@arm.com>
Thu, 15 Jun 2017 08:44:58 +0000 (09:44 +0100)
commit3106614e4b557f959169e9d35ef6a041760f1956
tree598f3fb8e246fe21daf83b816a7506fedaacda44
parent6e47730c2b0203d3571e0e40b63aeeb1bce36868
KVM: arm64: Make kvm_condition_valid32() accessible from EL2

As we're about to trap CP15 accesses and handle them at EL2, we
need to evaluate whether or not the condition flags are valid,
as an implementation is allowed to trap despite the condition
not being met.

Tagging the function as __hyp_text allows this. We still rely on
the cc_map array to be mapped at EL2 by virtue of being "const",
and the linker to only emit relative references.

Tested-by: Alexander Graf <agraf@suse.de>
Acked-by: David Daney <david.daney@cavium.com>
Reviewed-by: Eric Auger <eric.auger@redhat.com>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Christoffer Dall <cdall@linaro.org>
virt/kvm/arm/aarch32.c