Thread (80 messages) 80 messages, 3 authors, 2021-02-23

Re: [PATCH v3 09/66] KVM: arm64: nv: Support virtual EL2 exceptions

From: Marc Zyngier <maz@kernel.org>
Date: 2021-02-16 22:07:17
Also in: kvmarm, linux-arm-kernel

On Fri, 29 Jan 2021 18:05:39 +0000,
Andre Przywara [off-list ref] wrote:
On Thu, 10 Dec 2020 15:59:05 +0000
Marc Zyngier [off-list ref] wrote:
[...]
quoted
diff --git a/arch/arm64/kvm/inject_fault.c b/arch/arm64/kvm/inject_fault.c
index b47df73e98d7..530562eb09fd 100644
--- a/arch/arm64/kvm/inject_fault.c
+++ b/arch/arm64/kvm/inject_fault.c
@@ -14,17 +14,50 @@
 #include <asm/kvm_emulate.h>
 #include <asm/esr.h>
 
+static void pend_sync_exception(struct kvm_vcpu *vcpu)
+{
+	vcpu->arch.flags |= (KVM_ARM64_EXCEPT_AA64_ELx_SYNC	|
+			     KVM_ARM64_PENDING_EXCEPTION);
+
+	/* If not nesting, EL1 is the only possible exception target */
+	if (likely(!nested_virt_in_use(vcpu))) {
This breaks compilation for the next 14 patches, because
nested_virt_in_use() is unknown here. Patch 23/66 fixes this by adding
kvm_nested.h to kvm_emulate.h.
Indeed, well caught.
Shall we do this already in this patch here, or pull in kvm_nested.h in
every C file we use nested_virt_in_use(), like exception.c above?
I've just added kvm_nested.h in the two places that were required at
this stage (and verified that it all bisects correctly now).

Thanks,

	M.

-- 
Without deviation from the norm, progress is not possible.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help