I was trying to decouple components between block and qemu code, and reduce stub files. I found fixing some small code problem found could help, so pick up those which can benifit upstream code either and send them as separate series.
patch 1 to 4 comes from my RFC series earlier with title: Remove stub mon-protocol-event for block Wenchao Xia (13): 1 block: use type MonitorEvent directly 2 block: do not include monitor.h in block.c 3 qapi: move MonitorEvent define 4 qapi: rename MonitorEvent to QEvent 5 error: define struct Error in only one place 6 error: remove error_printf_unless_qmp() 7 error: make error_print_loc() static 8 error: don't set sep when print progname 9 error: print progname with error_vprintf() 10 qerror: deref once in qerror_report() 11 qerror: folder qerror emit logic 12 monitor: hide *cur_mon in monitor_get_fd() 13 stubs: do not call monitor_printf() block.c | 3 +- dump.c | 2 +- hw/usb/bus.c | 2 +- hw/usb/hcd-ehci.c | 4 +- include/block/block_int.h | 2 +- include/monitor/monitor.h | 42 ++------------------------- include/qapi/error.h | 5 ++- include/qapi/qmp/qevent.h | 66 +++++++++++++++++++++++++++++++++++++++++++ include/qapi/qmp/types.h | 1 + include/qemu/error-report.h | 2 - migration-fd.c | 2 +- monitor.c | 19 ++++++++---- qmp.c | 2 +- qobject/qerror.c | 36 ++++++++++------------- stubs/get-fd.c | 2 +- stubs/mon-protocol-event.c | 2 +- stubs/pci-drive-hot-add.c | 1 - ui/vnc.c | 2 +- util/error.c | 6 ---- util/qemu-error.c | 27 ++++++++---------- util/qemu-sockets.c | 4 +- 21 files changed, 127 insertions(+), 105 deletions(-) create mode 100644 include/qapi/qmp/qevent.h