Skip to content
  • Paolo Bonzini's avatar
    KVM: x86: clean/fix memory barriers in irqchip_in_kernel · 71ba994c
    Paolo Bonzini authored
    
    
    The memory barriers are trying to protect against concurrent RCU-based
    interrupt injection, but the IRQ routing table is not valid at the time
    kvm->arch.vpic is written.  Fix this by writing kvm->arch.vpic last.
    kvm_destroy_pic then need not set kvm->arch.vpic to NULL; modify it
    to take a struct kvm_pic* and reuse it if the IOAPIC creation fails.
    
    Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
    71ba994c