qemu-e2k/hw/usb
Philippe Mathieu-Daudé 083b266f69 chardev: Use QEMUChrEvent enum in IOEventHandler typedef
The Chardev events are listed in the QEMUChrEvent enum.

By using the enum in the IOEventHandler typedef we:

- make the IOEventHandler type more explicit (this handler
  process out-of-band information, while the IOReadHandler
  is in-band),
- help static code analyzers.

This patch was produced with the following spatch script:

  @match@
  expression backend, opaque, context, set_open;
  identifier fd_can_read, fd_read, fd_event, be_change;
  @@
  qemu_chr_fe_set_handlers(backend, fd_can_read, fd_read, fd_event,
                           be_change, opaque, context, set_open);

  @depends on match@
  identifier opaque, event;
  identifier match.fd_event;
  @@
   static
  -void fd_event(void *opaque, int event)
  +void fd_event(void *opaque, QEMUChrEvent event)
   {
   ...
   }

Then the typedef was modified manually in
include/chardev/char-fe.h.

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Acked-by: Corey Minyard <cminyard@mvista.com>
Acked-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20191218172009.8868-15-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2020-01-08 11:15:35 +01:00
..
Kconfig hw/usb: Remove the USB bluetooth dongle device 2019-12-16 17:24:07 +01:00
Makefile.objs hw/usb/redirect: Do not link 'usb-redir' device when USB not enabled 2020-01-07 12:08:39 +01:00
bus.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
ccid-card-emulated.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
ccid-card-passthru.c chardev: Use QEMUChrEvent enum in IOEventHandler typedef 2020-01-08 11:15:35 +01:00
ccid.h Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
chipidea.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
combined-packet.c Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
core.c Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
desc-msos.c usb: use local path for local headers 2018-06-01 19:20:38 +03:00
desc.c usb: use local path for local headers 2018-06-01 19:20:38 +03:00
desc.h all: Clean up includes 2016-02-23 12:43:05 +00:00
dev-audio.c usbaudio: change playback counters to 64 bit 2019-10-18 08:14:05 +02:00
dev-hid.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
dev-hub.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
dev-mtp.c usb-mtp: add sanity checks on rootdir 2019-08-29 07:31:12 +02:00
dev-network.c hw/usb: rename Error ** parameter to more common errp 2019-12-18 08:43:19 +01:00
dev-serial.c chardev: Use QEMUChrEvent enum in IOEventHandler typedef 2020-01-08 11:15:35 +01:00
dev-smartcard-reader.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
dev-storage.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
dev-uas.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
dev-wacom.c Include hw/hw.h exactly where needed 2019-08-16 13:31:52 +02:00
hcd-ehci-pci.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
hcd-ehci-sysbus.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
hcd-ehci.c ehci: fix queue->dev null ptr dereference 2019-08-22 06:55:29 +02:00
hcd-ehci.h sysemu: Move the VMChangeStateEntry typedef to qemu/typedefs.h 2019-08-16 13:31:53 +02:00
hcd-musb.c Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
hcd-ohci-pci.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
hcd-ohci.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
hcd-ohci.h hw/usb/hcd-ohci: Move PCI-related code into a separate file 2019-05-02 08:42:17 +02:00
hcd-uhci.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
hcd-xhci-nec.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
hcd-xhci.c xhci: Fix memory leak in xhci_kick_epctx 2019-08-29 07:30:04 +02:00
hcd-xhci.h Supply missing header guards 2019-06-12 13:20:21 +02:00
host-libusb.c usb-host: add option to allow all resets. 2019-11-06 13:26:04 +01:00
host-stub.c Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
host.h usb-host: move legacy cmd line bits 2013-02-19 12:30:05 +01:00
libhw.c Include hw/hw.h exactly where needed 2019-08-16 13:31:52 +02:00
quirks-ftdi-ids.h usbredir: Add support for buffered bulk input (v2) 2013-01-08 10:56:58 +01:00
quirks-pl2303-ids.h usbredir: Add support for buffered bulk input (v2) 2013-01-08 10:56:58 +01:00
quirks.c usb: Clean up includes 2016-01-29 15:07:23 +00:00
quirks.h Supply missing header guards 2019-06-12 13:20:21 +02:00
redirect.c chardev: Use QEMUChrEvent enum in IOEventHandler typedef 2020-01-08 11:15:35 +01:00
trace-events trace-events: Shorten file names in comments 2019-03-22 16:18:07 +00:00
tusb6010.c Include hw/hw.h exactly where needed 2019-08-16 13:31:52 +02:00
xen-usb.c Include qemu/main-loop.h less 2019-08-16 13:31:52 +02:00