Re: [PART1 RFC v2 06/10] svm: Add interrupt injection via AVIC

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 14/03/2016 10:41, Suravee Suthikulpanit wrote:
>>>>>>
>>>>>> +    kvm_lapic_set_vector(vec, avic_get_bk_page_entry(svm,
>>>>>> APIC_IRR));
>>>>
>>>> (I think that smp_mb here would make sense, even though we're fine now
>>>>   thanks to re-checking vcpu->mode in kvm_vcpu_kick.
>>>
>>> Right, though only a smp_mb__after_atomic() is required (which is a
>>> compiler barrier).  It is similarly required in vmx.
>>
>> True, kvm_lapic_set_vector uses a lock prefix.
>>
>> (I thought it behaves like atomic_set, which would require MFENCE for
>>   correct ordering here ... I don't like smp_mb__after_atomic much
>>   because of the discrepancy on some atomic operations.)
>>
> 
> So, should i just use smb_mb() in this case?

You should use smp_mb__after_atomic().

Paolo
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux