diff options
author | Marc Zyngier <maz@kernel.org> | 2020-04-23 16:27:33 +0100 |
---|---|---|
committer | Marc Zyngier <maz@kernel.org> | 2020-04-23 16:27:33 +0100 |
commit | 446c0768f5509793a0e527a439d4866b24707b0e (patch) | |
tree | ff8926db1a701b0276fb0deff6026956f632c961 /virt/kvm/arm/vgic/vgic-init.c | |
parent | 66f63474da4265f823503ea6b76037873d3f38fd (diff) | |
parent | 57bdb436ce869a45881d8aa4bc5dac8e072dd2b6 (diff) | |
download | linux-stable-446c0768f5509793a0e527a439d4866b24707b0e.tar.gz linux-stable-446c0768f5509793a0e527a439d4866b24707b0e.tar.bz2 linux-stable-446c0768f5509793a0e527a439d4866b24707b0e.zip |
Merge branch 'kvm-arm64/vgic-fixes-5.7' into kvmarm-master/master
Diffstat (limited to 'virt/kvm/arm/vgic/vgic-init.c')
-rw-r--r-- | virt/kvm/arm/vgic/vgic-init.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/virt/kvm/arm/vgic/vgic-init.c b/virt/kvm/arm/vgic/vgic-init.c index a963b9d766b7..30dbec9fe0b4 100644 --- a/virt/kvm/arm/vgic/vgic-init.c +++ b/virt/kvm/arm/vgic/vgic-init.c @@ -348,6 +348,12 @@ void kvm_vgic_vcpu_destroy(struct kvm_vcpu *vcpu) { struct vgic_cpu *vgic_cpu = &vcpu->arch.vgic_cpu; + /* + * Retire all pending LPIs on this vcpu anyway as we're + * going to destroy it. + */ + vgic_flush_pending_lpis(vcpu); + INIT_LIST_HEAD(&vgic_cpu->ap_list_head); } @@ -359,10 +365,10 @@ static void __kvm_vgic_destroy(struct kvm *kvm) vgic_debug_destroy(kvm); - kvm_vgic_dist_destroy(kvm); - kvm_for_each_vcpu(i, vcpu, kvm) kvm_vgic_vcpu_destroy(vcpu); + + kvm_vgic_dist_destroy(kvm); } void kvm_vgic_destroy(struct kvm *kvm) |