Re: high load with usb device

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

 



 On 09/14/2010 03:15 PM, Michael Tokarev wrote:
>
>>  - instrument calls to qemu_mod_timer() in hw/usb-*hci.c.  Looks like
>>  these are all 1kHz, but something else is clearly happening.

Ok. There's nothing interesting going on there either,
apparently.

It is using hw/usb-uhci.c.  I added a few prints() in there,
but they're firing at the defined 1KHz frequency.

Just for test, I lowered the frequency (FRAME_TIMER_FREQ)
from 1000 to 500, and the load dropped to half, from 19%
to 9..10%.

Looking at what hw/usb-uhci.c:uhci_frame_timer() routine
does, it is quite expected to have that many writes and
reads and that many gettimers().  It is polling for events
every 1/1000th of a second, instead of using some form of
select().


IIUC that's mandated by USB hardware. The guest may place data in memory, and USB polls it to see if it needs to tell send some message on the bus.

Please post an strace again, this time with -e trace=select. Looks like each timer callback results in >50 syscalls, 4 of which are select()s).



--
error compiling committee.c: too many arguments to function

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