Re: [Qemu-devel] [PATCH 3/3] virtio-pci: don't poll masked vectors

2012-12-19 Thread Stefan Hajnoczi
On Tue, Dec 18, 2012 at 02:39:19PM +0200, Michael S. Tsirkin wrote: > -static int virtio_pci_set_guest_notifier(DeviceState *d, int n, bool assign) > +static void kvm_virtio_pci_vector_poll(PCIDevice *dev, > + unsigned int vector_start, > +

Re: [Qemu-devel] [PATCH 3/3] virtio-pci: don't poll masked vectors

2012-12-19 Thread Michael S. Tsirkin
On Wed, Dec 19, 2012 at 04:59:05PM +0800, Asias He wrote: > On 12/18/2012 08:39 PM, Michael S. Tsirkin wrote: > > At the moment, when irqfd is in use but a vector is masked, > > qemu will poll it and handle vector masks in userspace. > > Since almost no one ever looks at the pending bits, > > it is

Re: [Qemu-devel] [PATCH 3/3] virtio-pci: don't poll masked vectors

2012-12-19 Thread Asias He
On 12/18/2012 08:39 PM, Michael S. Tsirkin wrote: > At the moment, when irqfd is in use but a vector is masked, > qemu will poll it and handle vector masks in userspace. > Since almost no one ever looks at the pending bits, > it is better to defer this until pending bits > are actually read. > Impl

[Qemu-devel] [PATCH 3/3] virtio-pci: don't poll masked vectors

2012-12-18 Thread Michael S. Tsirkin
At the moment, when irqfd is in use but a vector is masked, qemu will poll it and handle vector masks in userspace. Since almost no one ever looks at the pending bits, it is better to defer this until pending bits are actually read. Implement this optimization using the new poll notifier. Signed-o