qemu-e2k/hw/block
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
..
dataplane virtio-blk: fix out-of-bounds access to bitmap in notify_guest_bh 2019-12-19 16:20:25 +00:00
Kconfig hw/m68k: add a dummy SWIM floppy controller 2019-10-28 19:06:51 +01:00
Makefile.objs hw/m68k: add a dummy SWIM floppy controller 2019-10-28 19:06:51 +01:00
block.c pflash: Require backend size to match device, improve errors 2019-03-26 08:16:24 +01:00
cdrom.c Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
ecc.c Include hw/hw.h exactly where needed 2019-08-16 13:31:52 +02:00
fdc.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
hd-geometry.c block: Remove blk_pread_unthrottled() 2019-08-16 10:25:16 +02:00
m25p80.c m25p80: Add support for w25q512jv 2019-10-15 18:09:05 +01:00
nand.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
nvme.c Include hw/qdev-properties.h less 2019-08-16 13:31:53 +02:00
nvme.h nvme: add Get/Set Feature Timestamp support 2019-06-04 15:22:09 +02:00
onenand.c vmstate: replace DeviceState with VMStateIf 2020-01-06 18:41:32 +04:00
pflash_cfi01.c hw/block/pflash: Remove dynamic field width from trace events 2019-11-19 14:45:58 +01:00
pflash_cfi02.c hw/block/pflash: Remove dynamic field width from trace events 2019-11-19 14:45:58 +01:00
swim.c hw/m68k: add a dummy SWIM floppy controller 2019-10-28 19:06:51 +01:00
tc58128.c Include hw/hw.h exactly where needed 2019-08-16 13:31:52 +02:00
trace-events hw/block/pflash: Remove dynamic field width from trace events 2019-11-19 14:45:58 +01:00
vhost-user-blk.c chardev: Use QEMUChrEvent enum in IOEventHandler typedef 2020-01-08 11:15:35 +01:00
virtio-blk.c virtio-blk: advertise F_WCE (F_FLUSH) if F_CONFIG_WCE is advertised 2019-12-13 11:22:06 +00:00
xen-block.c xen-block: treat XenbusStateUnknown the same as XenbusStateClosed 2019-09-24 12:21:11 +01:00
xen_blkif.h xen: Import other xen/io/*.h 2019-06-24 10:42:30 +01:00