diff options
author | Hans de Goede <hdegoede@redhat.com> | 2012-11-17 12:47:18 +0100 |
---|---|---|
committer | Gerd Hoffmann <kraxel@redhat.com> | 2012-12-04 14:42:05 +0100 |
commit | 427e3aa151c749225364d0c30640e2e3c1756d9d (patch) | |
tree | f9389374da549cbe7587ec0ca530344ed0cbf58c /hw/pc_piix.c | |
parent | 8082624099bce56a3139e6b9f72016c00fd10227 (diff) |
usb-tablet: Allow connecting to ehci
Our ehci code has is capable of significantly lowering the wakeup rate
for the hcd emulation while the device is idle. It is possible to add
similar code ot the uhci emulation, but that simply is not there atm,
and there is no reason why a (virtual) usb-tablet can not be a USB-2 device.
Making usb-hid devices connect to the emulated ehci controller instead
of the emulated uhci controller on vms which have both lowers the cpuload
for a fully idle vm from 20% to 2-3% (on my laptop).
An alternative implementation to using a property to select the tablet
type, would be simply making it a new device type, ie usb-tablet2, but the
downside of that is that this will require libvirt changes to be available
through libvirt at all, and then management tools changes to become the
default for new vms, where as using a property will automatically get
any pc-1.3 type vms the lower cpuload.
[ kraxel: adapt compat property for post-1.3 merge ]
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
tablet compat fixup
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'hw/pc_piix.c')
-rw-r--r-- | hw/pc_piix.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/hw/pc_piix.c b/hw/pc_piix.c index 040cd079ed..19e342aeb4 100644 --- a/hw/pc_piix.c +++ b/hw/pc_piix.c @@ -290,17 +290,26 @@ static QEMUMachine pc_machine_v1_4 = { .is_default = 1, }; +#define PC_COMPAT_1_3 \ + {\ + .driver = "usb-tablet",\ + .property = "usb_version",\ + .value = stringify(1),\ + } + static QEMUMachine pc_machine_v1_3 = { .name = "pc-1.3", .desc = "Standard PC", .init = pc_init_pci_1_3, .max_cpus = 255, .compat_props = (GlobalProperty[]) { + PC_COMPAT_1_3, { /* end of list */ } }, }; #define PC_COMPAT_1_2 \ + PC_COMPAT_1_3,\ {\ .driver = "nec-usb-xhci",\ .property = "msi",\ |