Re: [patch uq/master 1/2] virtio-pci: wake up iothread on VIRTIO_PCI_QUEUE_NOTIFY

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

 



On 02/22/2010 09:16 AM, Marcelo Tosatti wrote:
Are you concerned about spurious wakeups?
Yes.  Also, qemu_notify_event() is an undirected notification (wakes
up all iothreads, and all devices), whereas ->handle_output() is
directed (wakes up exactly what is needed).

What's the underlying problem?  A new input buffer has become
available, and we need to re-poll the incoming file descriptor?  If
so, that's best done from ->handle_output() (either by waking the
iothread or calling read() itself and perhaps receiving -EAGAIN).
Yes. Sure, perhaps calling read() itself is appropriate, and i see
your point that>handle_output contains more context for a smarter
decision.

But one can argue thats an improvement on top of a dumb wakeup.

Spurious calls to qemu_notify_event() also make it difficult to tell when it's actually necessary to call qemu_notify_event() vs. when it's just something that doesn't hurt.

Regards,

Anthony Liguori

--
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

--
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