KVM: SVM: Process all IRTEs on affinity change even if one update fails

When updating IRTE GA fields, keep processing all other IRTEs if an update
fails, as not updating later entries risks making a bad situation worse.

Link: https://lore.kernel.org/r/20250611224604.313496-49-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
This commit is contained in:
Sean Christopherson 2025-06-11 15:45:50 -07:00
parent 16562766f1
commit 48f79c6c86

View File

@ -850,12 +850,10 @@ static inline int avic_update_iommu_vcpu_affinity(struct kvm_vcpu *vcpu, int cpu
if (list_empty(&svm->ir_list))
return 0;
list_for_each_entry(irqfd, &svm->ir_list, vcpu_list) {
list_for_each_entry(irqfd, &svm->ir_list, vcpu_list)
ret = amd_iommu_update_ga(cpu, irqfd->irq_bypass_data);
if (ret)
return ret;
}
return 0;
return ret;
}
void avic_vcpu_load(struct kvm_vcpu *vcpu, int cpu)