Commit graph

12 commits

Author SHA1 Message Date
Paolo Bonzini 49ab747f66 hw: move target-independent files to subdirectories
This patch tackles all files that are compiled once, moving
them to subdirectories of hw/.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-04-08 18:13:12 +02:00
Paolo Bonzini 0d09e41a51 hw: move headers to include/
Many of these should be cleaned up with proper qdev-/QOM-ification.
Right now there are many catch-all headers in include/hw/ARCH depending
on cpu.h, and this makes it necessary to compile these files per-target.
However, fixing this does not belong in these patches.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-04-08 18:13:10 +02:00
Paolo Bonzini 83c9f4ca79 hw: include hw header files with full paths
Done with this script:

cd hw
for i in `find . -name '*.h' | sed 's/^..//'`; do
  echo '\,^#.*include.*["<]'$i'[">], s,'$i',hw/&,'
done | sed -i -f - `find . -type f`

This is so that paths remain valid as files are moved.

Instead, files in hw/dataplane are referenced with the relative path.
We know they are not going to move to include/, and they are the only
include files that are in subdirectories _and_ move.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-03-01 15:01:17 +01:00
Hans de Goede 027c03f732 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>
2013-01-07 12:57:24 +01:00
Paolo Bonzini 1de7afc984 misc: move include files to include/qemu/
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2012-12-19 08:32:39 +01:00
Paolo Bonzini 28ecbaeecb ui: move files to ui/ and include/ui/
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2012-12-19 08:31:30 +01:00
Blue Swirl 18f88f1195 hid: fix misassignment
The code does not have any effect as is, fix it.

Spotted by clang analyzer:
/src/qemu/hw/hid.c:99:13: warning: Value stored to 'x1' is never read
            x1 = 1;

Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2011-09-10 14:49:51 +00:00
Michael Walle ccd4ed065b hid: introduce hid vmstate macros
Add VMSTATE macros to describe a HIDState. Based on usb-hid.c descriptions.

Signed-off-by: Michael Walle <michael@walle.cc>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2011-08-10 14:14:00 +02:00
Michael Walle bb0db5273f hid: register kbd hander in init()
Register the keyboard event handler in hid's init() instead of its reset()
function.

Signed-off-by: Michael Walle <michael@walle.cc>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2011-08-10 14:14:00 +02:00
Gerd Hoffmann 21635e121a usb/hid: add hid_pointer_activate, use it
HID reorganziation broke the usb tablet in windows xp.  The reason is
that xp activates idle before it starts polling, which creates a
chicken-and-egg issue:  We don't call hid_pointer_poll because there are
no pending events.  We don't get any events because the activation code
in hid_pointer_poll is never executed and thus all pointer events are
routed to the PS/2 mouse by qemu.

Fix this by creating a hid_pointer_activate function and call it from
usb-hid when the guest sets the idle state.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2011-08-10 14:14:00 +02:00
Gerd Hoffmann b069d3488f hid: move idle+protocol from usb-hid to hid too.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2011-08-04 15:51:51 +02:00
Gerd Hoffmann dcfda67310 usb-hid: split hid code to hw/hid.[ch]
Almost pure code motion.  Unstatic hid interface functions and add
them to the header file.  Some renames.  Some code style cleanups.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2011-08-04 15:51:51 +02:00