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

Marc Zyngier maz at kernel.org
Tue Feb 16 17:05:33 EST 2021


On Fri, 29 Jan 2021 18:05:39 +0000,
Andre Przywara <andre.przywara at arm.com> wrote:
> 
> On Thu, 10 Dec 2020 15:59:05 +0000
> Marc Zyngier <maz at kernel.org> wrote:

[...]

> > 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.



More information about the linux-arm-kernel mailing list