Skip to contentSkip to conversation

virtio: add guest MSI-X support

PATCH Superseded Michael S. Tsirkin 1 participant 1 message May 7, 2009 KVM

v2 of 6 Superseded Latest is v6 →

lore
Share & tools
lore
#0 lore raw

v2 cover virtio: add guest MSI-X support

Add optional MSI-X support: use a vector per virtqueue with fallback to a common vector and finally to regular interrupt. Teach all drivers to use it.

---

Here's a draft set of patches for MSI-X support in the guest. It still needs to be tested properly, and performance impact measured, but I thought I'd share it here in the hope of getting some very early feedback/flames.

Changelog since v1:
- Per Avi's suggestion, let guest configure virtqueue to vector mapping
- Per Rusty's suggestion, replace API with find_vqs/del_vqs.

Michael S. Tsirkin (3):
virtio: find_vqs/del_vqs virtio operations
virtio_pci: split up vp_interrupt
virtio_pci: optional MSI-X support

 drivers/block/virtio_blk.c          |   11 +-
 drivers/char/hw_random/virtio-rng.c |   11 +-
 drivers/char/virtio_console.c       |   27 ++--
 drivers/lguest/lguest_device.c      |   49 ++++++-
 drivers/net/virtio_net.c            |   47 +++----
 drivers/s390/kvm/kvm_virtio.c       |   64 ++++++++-
 drivers/virtio/virtio_balloon.c     |   31 ++--
 drivers/virtio/virtio_pci.c         |  283 ++++++++++++++++++++++++++++++-----
 include/linux/virtio_config.h       |   29 +++-
 include/linux/virtio_pci.h          |    8 +-
 10 files changed, 440 insertions(+), 120 deletions(-)