hid: Change idle handling to use a timer
commit027c03f7327faa696e1d876954a18b5214c18583
authorHans de Goede <hdegoede@redhat.com>
Fri, 14 Dec 2012 13:35:38 +0000 (14 14:35 +0100)
committerGerd Hoffmann <kraxel@redhat.com>
Mon, 7 Jan 2013 11:57:24 +0000 (7 12:57 +0100)
treee3cf765c7fddf3304ec994ab0dead4e5fc665289
parent9fdf70272702095f57efc51a80c79493fd0829b8
hid: Change idle handling to use a timer

This leads to cleaner code in usb-hid, and removes up to a 1000 calls / sec to
qemu_get_clock_ns(vm_clock) if idle-time is set to its default value of 0.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
hw/hid.c
hw/hid.h
hw/usb/dev-hid.c