2011-01-14 00:09:15 +08:00
|
|
|
name "pci-bridge", bus PCI
|
|
|
|
name "virtio-balloon-pci", bus PCI
|
|
|
|
name "virtio-serial-pci", bus PCI, alias "virtio-serial"
|
|
|
|
name "virtio-net-pci", bus PCI
|
|
|
|
name "virtio-blk-pci", bus PCI
|
|
|
|
name "sysbus-ohci", bus System, desc "OHCI USB Controller"
|
|
|
|
name "pci-ohci", bus PCI, desc "Apple USB Controller"
|
|
|
|
name "rtl8139", bus PCI
|
|
|
|
name "e1000", bus PCI, desc "Intel Gigabit Ethernet"
|
|
|
|
name "ivshmem", bus PCI
|
|
|
|
name "smbus-eeprom", bus I2C
|
|
|
|
name "scsi-disk", bus SCSI, desc "virtual scsi disk or cdrom"
|
|
|
|
name "scsi-generic", bus SCSI, desc "pass through generic scsi device (/dev/sg*)"
|
|
|
|
name "usb-hub", bus USB
|
|
|
|
name "usb-host", bus USB
|
|
|
|
name "usb-kbd", bus USB
|
|
|
|
name "usb-mouse", bus USB
|
|
|
|
name "usb-tablet", bus USB
|
|
|
|
name "usb-storage", bus USB
|
|
|
|
name "usb-wacom-tablet", bus USB, desc "QEMU PenPartner Tablet"
|
|
|
|
name "usb-braille", bus USB
|
|
|
|
name "usb-serial", bus USB
|
|
|
|
name "usb-net", bus USB
|
|
|
|
name "usb-bt-dongle", bus USB
|
|
|
|
name "virtconsole", bus virtio-serial-bus
|
|
|
|
name "virtserialport", bus virtio-serial-bus
|
|
|
|
name "isa-serial", bus ISA
|
|
|
|
name "isa-parallel", bus ISA
|
|
|
|
name "vt82c686b-usb-uhci", bus PCI
|
|
|
|
name "piix4-usb-uhci", bus PCI
|
|
|
|
name "piix3-usb-uhci", bus PCI
|
|
|
|
name "SUNW,fdtwo", bus System
|
|
|
|
name "sysbus-fdc", bus System
|
|
|
|
name "i6300esb", bus PCI
|
|
|
|
name "ne2k_pci", bus PCI
|
|
|
|
name "i82801", bus PCI, desc "Intel i82801 Ethernet"
|
|
|
|
name "i82562", bus PCI, desc "Intel i82562 Ethernet"
|
|
|
|
name "i82559er", bus PCI, desc "Intel i82559ER Ethernet"
|
|
|
|
name "i82559c", bus PCI, desc "Intel i82559C Ethernet"
|
|
|
|
name "i82559b", bus PCI, desc "Intel i82559B Ethernet"
|
|
|
|
name "i82559a", bus PCI, desc "Intel i82559A Ethernet"
|
|
|
|
name "i82558b", bus PCI, desc "Intel i82558B Ethernet"
|
|
|
|
name "i82558a", bus PCI, desc "Intel i82558A Ethernet"
|
|
|
|
name "i82557c", bus PCI, desc "Intel i82557C Ethernet"
|
|
|
|
name "i82557b", bus PCI, desc "Intel i82557B Ethernet"
|
|
|
|
name "i82557a", bus PCI, desc "Intel i82557A Ethernet"
|
|
|
|
name "i82551", bus PCI, desc "Intel i82551 Ethernet"
|
|
|
|
name "i82550", bus PCI, desc "Intel i82550 Ethernet"
|
|
|
|
name "pcnet", bus PCI
|
|
|
|
name "ne2k_isa", bus ISA
|
|
|
|
name "ide-drive", bus IDE
|
|
|
|
name "isa-ide", bus ISA
|
|
|
|
name "lsi53c895a", bus PCI, alias "lsi"
|
|
|
|
name "VGA", bus PCI
|
|
|
|
name "vmware-svga", bus PCI
|
|
|
|
name "sb16", bus ISA, desc "Creative Sound Blaster 16"
|
|
|
|
name "ES1370", bus PCI, desc "ENSONIQ AudioPCI ES1370"
|
|
|
|
name "AC97", bus PCI, desc "Intel 82801AA AC97 Audio"
|
|
|
|
name "cirrus-vga", bus PCI, desc "Cirrus CLGD 54xx VGA"
|
|
|
|
name "isa-applesmc", bus ISA
|
|
|
|
name "ib700", bus ISA
|
|
|
|
name "isa-debugcon", bus ISA
|
|
|
|
name "testdev", bus ISA
|
|
|
|
name "PIIX4_PM", bus PCI, desc "PM"
|
|
|
|
name "qxl", bus PCI, desc "Spice QXL GPU"
|
|
|
|
name "spicevmc", bus virtio-serial-bus
|
|
|
|
name "pci-assign", bus PCI, desc "pass through host pci devices to the guest"
|
|
|
|
pci-assign.host=pci-hostaddr
|
|
|
|
pci-assign.iommu=uint32
|
|
|
|
pci-assign.configfd=string
|
Add txmode attribute to interface XML for virtio backend
This is in response to:
https://bugzilla.redhat.com/show_bug.cgi?id=629662
Explanation
qemu's virtio-net-pci driver allows setting the algorithm used for tx
packets to either "bh" or "timer". This is done by adding ",tx=bh" or
",tx=timer" to the "-device virtio-net-pci" commandline option.
'bh' stands for 'bottom half'; when this is set, packet tx is all done
in an iothread in the bottom half of the driver. (In libvirt, this
option is called the more descriptive "iothread".)
'timer' means that tx work is done in qemu, and if there is more tx
data than can be sent at the present time, a timer is set before qemu
moves on to do other things; when the timer fires, another attempt is
made to send more data. (libvirt retains the name "timer" for this
option.)
The resulting difference, according to the qemu developer who added
the option is:
bh makes tx more asynchronous and reduces latency, but potentially
causes more processor bandwidth contention since the cpu doing the
tx isn't necessarily the cpu where the guest generated the
packets.
Solution
This patch provides a libvirt domain xml knob to change the option on
the qemu commandline, by adding a new attribute "txmode" to the
<driver> element that can be placed inside any <interface> element in
a domain definition. It's use would be something like this:
<interface ...>
...
<model type='virtio'/>
<driver txmode='iothread'/>
...
</interface>
I chose to put this setting as an attribute to <driver> rather than as
a sub-element to <tune> because it is specific to the virtio-net
driver, not something that is generally usable by all network drivers.
(note that this is the same placement as the "driver name=..."
attribute used to choose kernel vs. userland backend for the
virtio-net driver.)
Actually adding the tx=xxx option to the qemu commandline is only done
if the version of qemu being used advertises it in the output of
qemu -device virtio-net-pci,?
If a particular txmode is requested in the XML, and the option isn't
listed in that help output, an UNSUPPORTED_CONFIG error is logged, and
the domain fails to start.
2011-02-04 04:20:01 +08:00
|
|
|
virtio-net-pci.vectors=uint32
|
|
|
|
virtio-net-pci.indirect_desc=on/off
|
|
|
|
virtio-net-pci.csum=on/off
|
|
|
|
virtio-net-pci.guest_csum=on/off
|
|
|
|
virtio-net-pci.gso=on/off
|
|
|
|
virtio-net-pci.guest_tso4=on/off
|
|
|
|
virtio-net-pci.guest_tso6=on/off
|
|
|
|
virtio-net-pci.guest_ecn=on/off
|
|
|
|
virtio-net-pci.guest_ufo=on/off
|
|
|
|
virtio-net-pci.host_tso4=on/off
|
|
|
|
virtio-net-pci.host_tso6=on/off
|
|
|
|
virtio-net-pci.host_ecn=on/off
|
|
|
|
virtio-net-pci.host_ufo=on/off
|
|
|
|
virtio-net-pci.mrg_rxbuf=on/off
|
|
|
|
virtio-net-pci.status=on/off
|
|
|
|
virtio-net-pci.ctrl_vq=on/off
|
|
|
|
virtio-net-pci.ctrl_rx=on/off
|
|
|
|
virtio-net-pci.ctrl_vlan=on/off
|
|
|
|
virtio-net-pci.ctrl_rx_extra=on/off
|
|
|
|
virtio-net-pci.mac=macaddr
|
|
|
|
virtio-net-pci.vlan=vlan
|
|
|
|
virtio-net-pci.netdev=netdev
|