Re: [Qemu-devel] [PATCH for-2.11] intel_iommu: fix missing BQL in pt fast path

2017-08-18 Thread Paolo Bonzini
On 18/08/2017 06:02, Peter Xu wrote: >> The patch below is okay. However, vtd_switch_address_space is >> expensive, which is why I suggested the bottom half. > But still, shall we just do it this way? It looks cleaner. > > For the slowness (as I mentioned below), one thing to mention is that, > t

Re: [Qemu-devel] [PATCH for-2.11] intel_iommu: fix missing BQL in pt fast path

2017-08-17 Thread Peter Xu
On Thu, Aug 17, 2017 at 11:40:48AM +0200, Paolo Bonzini wrote: > On 17/08/2017 07:56, Peter Xu wrote: > > In vtd_switch_address_space() we did the memory region switch, however > > it's possible that the caller of it has not taken the BQL at all. Make > > sure we have it. > > > > CC: Paolo Bonzini

Re: [Qemu-devel] [PATCH for-2.11] intel_iommu: fix missing BQL in pt fast path

2017-08-17 Thread Paolo Bonzini
On 17/08/2017 07:56, Peter Xu wrote: > In vtd_switch_address_space() we did the memory region switch, however > it's possible that the caller of it has not taken the BQL at all. Make > sure we have it. > > CC: Paolo Bonzini > CC: Jason Wang > CC: Michael S. Tsirkin > Signed-off-by: Peter Xu >

[Qemu-devel] [PATCH for-2.11] intel_iommu: fix missing BQL in pt fast path

2017-08-16 Thread Peter Xu
In vtd_switch_address_space() we did the memory region switch, however it's possible that the caller of it has not taken the BQL at all. Make sure we have it. CC: Paolo Bonzini CC: Jason Wang CC: Michael S. Tsirkin Signed-off-by: Peter Xu --- Paolo: I noticed this qemu_mutex_iothread_locked()