aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2015-03-17 17:22:46 +0100
committerMarkus Armbruster <armbru@redhat.com>2015-06-22 18:20:41 +0200
commitcc7a8ea740ec74a144e866a1d24aa6b490e31923 (patch)
tree1bb5f94977aa90e5163360cb1dd2e9a4d0f94ee8
parentd49b68364414d649b8e26232f2a600d415611662 (diff)
Include qapi/qmp/qerror.h exactly where needed
In particular, don't include it into headers. Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Luiz Capitulino <lcapitulino@redhat.com>
-rw-r--r--backends/hostmem.c1
-rw-r--r--balloon.c1
-rw-r--r--block.c1
-rw-r--r--block/backup.c1
-rw-r--r--block/commit.c1
-rw-r--r--block/mirror.c1
-rw-r--r--block/qcow.c1
-rw-r--r--block/quorum.c1
-rw-r--r--block/snapshot.c1
-rw-r--r--block/stream.c1
-rw-r--r--block/vmdk.c1
-rw-r--r--blockdev.c1
-rw-r--r--blockjob.c1
-rw-r--r--dump.c1
-rw-r--r--hmp.c1
-rw-r--r--hw/char/serial-pci.c1
-rw-r--r--hw/dma/xilinx_axidma.c1
-rw-r--r--hw/misc/ivshmem.c1
-rw-r--r--hw/net/xilinx_axienet.c1
-rw-r--r--hw/pci/pci-stub.c1
-rw-r--r--hw/pci/pcie.c1
-rw-r--r--hw/pci/shpc.c1
-rw-r--r--hw/ppc/virtex_ml507.c1
-rw-r--r--hw/s390x/s390-virtio.c1
-rw-r--r--hw/usb/redirect.c1
-rw-r--r--hw/virtio/virtio-rng.c1
-rw-r--r--include/block/block_int.h1
-rw-r--r--include/monitor/monitor.h1
-rw-r--r--include/qemu/sockets.h1
-rw-r--r--migration/migration.c1
-rw-r--r--migration/savevm.c1
-rw-r--r--monitor.c1
-rw-r--r--net/net.c1
-rw-r--r--numa.c1
-rw-r--r--qapi/qmp-output-visitor.c1
-rw-r--r--qapi/string-output-visitor.c1
-rw-r--r--qdev-monitor.c1
-rw-r--r--qemu-img.c1
-rw-r--r--qmp.c1
-rw-r--r--qobject/json-parser.c1
-rw-r--r--scripts/qapi-commands.py1
-rw-r--r--stubs/dump.c1
-rw-r--r--target-arm/cpu.c1
-rw-r--r--target-i386/kvm.c1
-rw-r--r--ui/vnc.c1
-rw-r--r--util/qemu-config.c1
46 files changed, 25 insertions, 21 deletions
diff --git a/backends/hostmem.c b/backends/hostmem.c
index 7d74be04c3..61c1ac0843 100644
--- a/backends/hostmem.c
+++ b/backends/hostmem.c
@@ -13,7 +13,6 @@
#include "qapi/visitor.h"
#include "qapi-types.h"
#include "qapi-visit.h"
-#include "qapi/qmp/qerror.h"
#include "qemu/config-file.h"
#include "qom/object_interfaces.h"
diff --git a/balloon.c b/balloon.c
index 5f5202c25e..617187adf3 100644
--- a/balloon.c
+++ b/balloon.c
@@ -30,6 +30,7 @@
#include "sysemu/balloon.h"
#include "trace.h"
#include "qmp-commands.h"
+#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qjson.h"
static QEMUBalloonEvent *balloon_event_fn;
diff --git a/block.c b/block.c
index b07f987f36..e2e33fd085 100644
--- a/block.c
+++ b/block.c
@@ -28,6 +28,7 @@
#include "block/blockjob.h"
#include "qemu/error-report.h"
#include "qemu/module.h"
+#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qjson.h"
#include "sysemu/block-backend.h"
#include "sysemu/sysemu.h"
diff --git a/block/backup.c b/block/backup.c
index 35145cbe03..4a1af68c32 100644
--- a/block/backup.c
+++ b/block/backup.c
@@ -19,6 +19,7 @@
#include "block/block.h"
#include "block/block_int.h"
#include "block/blockjob.h"
+#include "qapi/qmp/qerror.h"
#include "qemu/ratelimit.h"
#define BACKUP_CLUSTER_BITS 16
diff --git a/block/commit.c b/block/commit.c
index 6c01feaa06..7312a5bdc0 100644
--- a/block/commit.c
+++ b/block/commit.c
@@ -15,6 +15,7 @@
#include "trace.h"
#include "block/block_int.h"
#include "block/blockjob.h"
+#include "qapi/qmp/qerror.h"
#include "qemu/ratelimit.h"
enum {
diff --git a/block/mirror.c b/block/mirror.c
index e3e51a2cce..048e452d17 100644
--- a/block/mirror.c
+++ b/block/mirror.c
@@ -14,6 +14,7 @@
#include "trace.h"
#include "block/blockjob.h"
#include "block/block_int.h"
+#include "qapi/qmp/qerror.h"
#include "qemu/ratelimit.h"
#include "qemu/bitmap.h"
diff --git a/block/qcow.c b/block/qcow.c
index 54152f9974..733627fbf2 100644
--- a/block/qcow.c
+++ b/block/qcow.c
@@ -25,6 +25,7 @@
#include "block/block_int.h"
#include "qemu/module.h"
#include <zlib.h>
+#include "qapi/qmp/qerror.h"
#include "qemu/aes.h"
#include "migration/migration.h"
diff --git a/block/quorum.c b/block/quorum.c
index 9aceabd1b3..a7df17c185 100644
--- a/block/quorum.c
+++ b/block/quorum.c
@@ -18,6 +18,7 @@
#include "block/block_int.h"
#include "qapi/qmp/qbool.h"
#include "qapi/qmp/qdict.h"
+#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qint.h"
#include "qapi/qmp/qjson.h"
#include "qapi/qmp/qlist.h"
diff --git a/block/snapshot.c b/block/snapshot.c
index 7cd960cda7..19395ae014 100644
--- a/block/snapshot.c
+++ b/block/snapshot.c
@@ -24,6 +24,7 @@
#include "block/snapshot.h"
#include "block/block_int.h"
+#include "qapi/qmp/qerror.h"
QemuOptsList internal_snapshot_opts = {
.name = "snapshot",
diff --git a/block/stream.c b/block/stream.c
index f17efdb90f..ab0bd057f7 100644
--- a/block/stream.c
+++ b/block/stream.c
@@ -14,6 +14,7 @@
#include "trace.h"
#include "block/block_int.h"
#include "block/blockjob.h"
+#include "qapi/qmp/qerror.h"
#include "qemu/ratelimit.h"
enum {
diff --git a/block/vmdk.c b/block/vmdk.c
index b7f3f213ea..fbaab67c8f 100644
--- a/block/vmdk.c
+++ b/block/vmdk.c
@@ -25,6 +25,7 @@
#include "qemu-common.h"
#include "block/block_int.h"
+#include "qapi/qmp/qerror.h"
#include "qemu/error-report.h"
#include "qemu/module.h"
#include "migration/migration.h"
diff --git a/blockdev.c b/blockdev.c
index fdc7768ce5..b35467646e 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -41,6 +41,7 @@
#include "qemu/config-file.h"
#include "qapi/qmp/types.h"
#include "qapi-visit.h"
+#include "qapi/qmp/qerror.h"
#include "qapi/qmp-output-visitor.h"
#include "qapi/util.h"
#include "sysemu/sysemu.h"
diff --git a/blockjob.c b/blockjob.c
index b033f6855e..ec46fad2f1 100644
--- a/blockjob.c
+++ b/blockjob.c
@@ -29,6 +29,7 @@
#include "block/block.h"
#include "block/blockjob.h"
#include "block/block_int.h"
+#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qjson.h"
#include "block/coroutine.h"
#include "qmp-commands.h"
diff --git a/dump.c b/dump.c
index 9a02b51a1f..78b7d843ce 100644
--- a/dump.c
+++ b/dump.c
@@ -23,6 +23,7 @@
#include "sysemu/memory_mapping.h"
#include "sysemu/cpus.h"
#include "qapi/error.h"
+#include "qapi/qmp/qerror.h"
#include "qmp-commands.h"
#include <zlib.h>
diff --git a/hmp.c b/hmp.c
index fd10ab51b4..070aaf814f 100644
--- a/hmp.c
+++ b/hmp.c
@@ -25,6 +25,7 @@
#include "monitor/monitor.h"
#include "monitor/qdev.h"
#include "qapi/opts-visitor.h"
+#include "qapi/qmp/qerror.h"
#include "qapi/string-output-visitor.h"
#include "qapi-visit.h"
#include "ui/console.h"
diff --git a/hw/char/serial-pci.c b/hw/char/serial-pci.c
index 653064fadf..1c8b9be5cc 100644
--- a/hw/char/serial-pci.c
+++ b/hw/char/serial-pci.c
@@ -27,7 +27,6 @@
#include "hw/char/serial.h"
#include "hw/pci/pci.h"
-#include "qapi/qmp/qerror.h"
#define PCI_SERIAL_MAX_PORTS 4
diff --git a/hw/dma/xilinx_axidma.c b/hw/dma/xilinx_axidma.c
index d06002dde8..cf842a3cc7 100644
--- a/hw/dma/xilinx_axidma.c
+++ b/hw/dma/xilinx_axidma.c
@@ -26,7 +26,6 @@
#include "qemu/timer.h"
#include "hw/ptimer.h"
#include "qemu/log.h"
-#include "qapi/qmp/qerror.h"
#include "qemu/main-loop.h"
#include "hw/stream.h"
diff --git a/hw/misc/ivshmem.c b/hw/misc/ivshmem.c
index 53d19fcf1d..cc76989a39 100644
--- a/hw/misc/ivshmem.c
+++ b/hw/misc/ivshmem.c
@@ -22,7 +22,6 @@
#include "hw/pci/msix.h"
#include "sysemu/kvm.h"
#include "migration/migration.h"
-#include "qapi/qmp/qerror.h"
#include "qemu/error-report.h"
#include "qemu/event_notifier.h"
#include "qemu/fifo8.h"
diff --git a/hw/net/xilinx_axienet.c b/hw/net/xilinx_axienet.c
index 21efedfc3e..92057707e0 100644
--- a/hw/net/xilinx_axienet.c
+++ b/hw/net/xilinx_axienet.c
@@ -26,7 +26,6 @@
#include "qemu/log.h"
#include "net/net.h"
#include "net/checksum.h"
-#include "qapi/qmp/qerror.h"
#include "hw/stream.h"
diff --git a/hw/pci/pci-stub.c b/hw/pci/pci-stub.c
index 9b51d3782f..063a7c2427 100644
--- a/hw/pci/pci-stub.c
+++ b/hw/pci/pci-stub.c
@@ -20,6 +20,7 @@
#include "sysemu/sysemu.h"
#include "monitor/monitor.h"
+#include "qapi/qmp/qerror.h"
#include "hw/pci/pci.h"
#include "qmp-commands.h"
diff --git a/hw/pci/pcie.c b/hw/pci/pcie.c
index 1463e65b5d..14c77117f6 100644
--- a/hw/pci/pcie.c
+++ b/hw/pci/pcie.c
@@ -26,7 +26,6 @@
#include "hw/pci/pci_bus.h"
#include "hw/pci/pcie_regs.h"
#include "qemu/range.h"
-#include "qapi/qmp/qerror.h"
//#define DEBUG_PCIE
#ifdef DEBUG_PCIE
diff --git a/hw/pci/shpc.c b/hw/pci/shpc.c
index a706486394..bfb4d31b62 100644
--- a/hw/pci/shpc.c
+++ b/hw/pci/shpc.c
@@ -7,7 +7,6 @@
#include "hw/pci/pci.h"
#include "hw/pci/pci_bus.h"
#include "hw/pci/msi.h"
-#include "qapi/qmp/qerror.h"
/* TODO: model power only and disabled slot states. */
/* TODO: handle SERR and wakeups */
diff --git a/hw/ppc/virtex_ml507.c b/hw/ppc/virtex_ml507.c
index 6feb3c7c39..439732f7ab 100644
--- a/hw/ppc/virtex_ml507.c
+++ b/hw/ppc/virtex_ml507.c
@@ -41,7 +41,6 @@
#include "ppc405.h"
#include "sysemu/block-backend.h"
-#include "qapi/qmp/qerror.h"
#define EPAPR_MAGIC (0x45504150)
#define FLASH_SIZE (16 * 1024 * 1024)
diff --git a/hw/s390x/s390-virtio.c b/hw/s390x/s390-virtio.c
index be2ba86685..4a67c3fc1e 100644
--- a/hw/s390x/s390-virtio.c
+++ b/hw/s390x/s390-virtio.c
@@ -22,6 +22,7 @@
*/
#include "hw/hw.h"
+#include "qapi/qmp/qerror.h"
#include "sysemu/block-backend.h"
#include "sysemu/blockdev.h"
#include "sysemu/sysemu.h"
diff --git a/hw/usb/redirect.c b/hw/usb/redirect.c
index 110e0149b5..4e9528e0ab 100644
--- a/hw/usb/redirect.c
+++ b/hw/usb/redirect.c
@@ -29,6 +29,7 @@
#include "qemu/timer.h"
#include "monitor/monitor.h"
#include "sysemu/sysemu.h"
+#include "qapi/qmp/qerror.h"
#include "qemu/error-report.h"
#include "qemu/iov.h"
#include "sysemu/char.h"
diff --git a/hw/virtio/virtio-rng.c b/hw/virtio/virtio-rng.c
index 22b1d87d0e..740ed3102b 100644
--- a/hw/virtio/virtio-rng.c
+++ b/hw/virtio/virtio-rng.c
@@ -11,7 +11,6 @@
#include "qemu/iov.h"
#include "hw/qdev.h"
-#include "qapi/qmp/qerror.h"
#include "hw/virtio/virtio.h"
#include "hw/virtio/virtio-rng.h"
#include "sysemu/rng.h"
diff --git a/include/block/block_int.h b/include/block/block_int.h
index 888ec09e96..a81542c9c2 100644
--- a/include/block/block_int.h
+++ b/include/block/block_int.h
@@ -31,7 +31,6 @@
#include "block/coroutine.h"
#include "qemu/timer.h"
#include "qapi-types.h"
-#include "qapi/qmp/qerror.h"
#include "monitor/monitor.h"
#include "qemu/hbitmap.h"
#include "block/snapshot.h"
diff --git a/include/monitor/monitor.h b/include/monitor/monitor.h
index aa831043eb..9aff47e699 100644
--- a/include/monitor/monitor.h
+++ b/include/monitor/monitor.h
@@ -2,7 +2,6 @@
#define MONITOR_H
#include "qemu-common.h"
-#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qdict.h"
#include "block/block.h"
#include "qemu/readline.h"
diff --git a/include/qemu/sockets.h b/include/qemu/sockets.h
index 7992ece72a..c174b5cbdd 100644
--- a/include/qemu/sockets.h
+++ b/include/qemu/sockets.h
@@ -28,7 +28,6 @@ int inet_aton(const char *cp, struct in_addr *ia);
#include "qemu/option.h"
#include "qapi/error.h"
-#include "qapi/qmp/qerror.h"
#include "qapi-types.h"
extern QemuOptsList socket_optslist;
diff --git a/migration/migration.c b/migration/migration.c
index 25f6830a77..d7056d7453 100644
--- a/migration/migration.c
+++ b/migration/migration.c
@@ -21,6 +21,7 @@
#include "migration/qemu-file.h"
#include "sysemu/sysemu.h"
#include "block/block.h"
+#include "qapi/qmp/qerror.h"
#include "qemu/sockets.h"
#include "migration/block.h"
#include "qemu/thread.h"
diff --git a/migration/savevm.c b/migration/savevm.c
index 2b4e02f1a3..9e0e286797 100644
--- a/migration/savevm.c
+++ b/migration/savevm.c
@@ -37,6 +37,7 @@
#include "qemu/timer.h"
#include "audio/audio.h"
#include "migration/migration.h"
+#include "qapi/qmp/qerror.h"
#include "qemu/error-report.h"
#include "qemu/sockets.h"
#include "qemu/queue.h"
diff --git a/monitor.c b/monitor.c
index 497fed289e..aeea2b5f9e 100644
--- a/monitor.c
+++ b/monitor.c
@@ -49,6 +49,7 @@
#include "sysemu/kvm.h"
#include "qemu/acl.h"
#include "sysemu/tpm.h"
+#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qint.h"
#include "qapi/qmp/qfloat.h"
#include "qapi/qmp/qlist.h"
diff --git a/net/net.c b/net/net.c
index 19184e46bc..cc36c7b4fe 100644
--- a/net/net.c
+++ b/net/net.c
@@ -32,6 +32,7 @@
#include "monitor/monitor.h"
#include "qemu-common.h"
+#include "qapi/qmp/qerror.h"
#include "qemu/error-report.h"
#include "qemu/sockets.h"
#include "qemu/config-file.h"
diff --git a/numa.c b/numa.c
index 28c857c66a..91fc6c1d93 100644
--- a/numa.c
+++ b/numa.c
@@ -31,7 +31,6 @@
#include "qapi-visit.h"
#include "qapi/opts-visitor.h"
#include "qapi/dealloc-visitor.h"
-#include "qapi/qmp/qerror.h"
#include "hw/boards.h"
#include "sysemu/hostmem.h"
#include "qmp-commands.h"
diff --git a/qapi/qmp-output-visitor.c b/qapi/qmp-output-visitor.c
index 7e0f7ce16a..efc19d5841 100644
--- a/qapi/qmp-output-visitor.c
+++ b/qapi/qmp-output-visitor.c
@@ -16,7 +16,6 @@
#include "qemu/queue.h"
#include "qemu-common.h"
#include "qapi/qmp/types.h"
-#include "qapi/qmp/qerror.h"
typedef struct QStackEntry
{
diff --git a/qapi/string-output-visitor.c b/qapi/string-output-visitor.c
index 1ab8574585..b86ce2cd07 100644
--- a/qapi/string-output-visitor.c
+++ b/qapi/string-output-visitor.c
@@ -13,7 +13,6 @@
#include "qemu-common.h"
#include "qapi/string-output-visitor.h"
#include "qapi/visitor-impl.h"
-#include "qapi/qmp/qerror.h"
#include "qemu/host-utils.h"
#include <math.h>
#include "qemu/range.h"
diff --git a/qdev-monitor.c b/qdev-monitor.c
index 66f6d0e26a..f9e2d6258d 100644
--- a/qdev-monitor.c
+++ b/qdev-monitor.c
@@ -23,6 +23,7 @@
#include "monitor/qdev.h"
#include "qmp-commands.h"
#include "sysemu/arch_init.h"
+#include "qapi/qmp/qerror.h"
#include "qemu/config-file.h"
#include "qemu/error-report.h"
diff --git a/qemu-img.c b/qemu-img.c
index 6d1b1364e1..75f4ee4421 100644
--- a/qemu-img.c
+++ b/qemu-img.c
@@ -23,6 +23,7 @@
*/
#include "qapi-visit.h"
#include "qapi/qmp-output-visitor.h"
+#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qjson.h"
#include "qemu-common.h"
#include "qemu/option.h"
diff --git a/qmp.c b/qmp.c
index a046b68c99..03eba96193 100644
--- a/qmp.c
+++ b/qmp.c
@@ -24,6 +24,7 @@
#include "hw/qdev.h"
#include "sysemu/blockdev.h"
#include "qom/qom-qobject.h"
+#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qobject.h"
#include "qapi/qmp-input-visitor.h"
#include "hw/boards.h"
diff --git a/qobject/json-parser.c b/qobject/json-parser.c
index 015d7855f5..ac991ba3cf 100644
--- a/qobject/json-parser.c
+++ b/qobject/json-parser.c
@@ -22,7 +22,6 @@
#include "qapi/qmp/qbool.h"
#include "qapi/qmp/json-parser.h"
#include "qapi/qmp/json-lexer.h"
-#include "qapi/qmp/qerror.h"
typedef struct JSONParserContext
{
diff --git a/scripts/qapi-commands.py b/scripts/qapi-commands.py
index a451a51bce..ca22acc1d5 100644
--- a/scripts/qapi-commands.py
+++ b/scripts/qapi-commands.py
@@ -329,7 +329,6 @@ h_comment = '''
fdef.write(mcgen('''
#include "qemu-common.h"
#include "qemu/module.h"
-#include "qapi/qmp/qerror.h"
#include "qapi/qmp/types.h"
#include "qapi/qmp/dispatch.h"
#include "qapi/visitor.h"
diff --git a/stubs/dump.c b/stubs/dump.c
index fac70191eb..8c24eda847 100644
--- a/stubs/dump.c
+++ b/stubs/dump.c
@@ -13,7 +13,6 @@
#include "qemu-common.h"
#include "sysemu/dump-arch.h"
-#include "qapi/qmp/qerror.h"
#include "qmp-commands.h"
int cpu_get_dump_info(ArchDumpInfo *info,
diff --git a/target-arm/cpu.c b/target-arm/cpu.c
index b3d07ac7d8..80669a6d1b 100644
--- a/target-arm/cpu.c
+++ b/target-arm/cpu.c
@@ -22,7 +22,6 @@
#include "internals.h"
#include "qemu-common.h"
#include "hw/qdev-properties.h"
-#include "qapi/qmp/qerror.h"
#if !defined(CONFIG_USER_ONLY)
#include "hw/loader.h"
#endif
diff --git a/target-i386/kvm.c b/target-i386/kvm.c
index 5a236e3103..daced5cb94 100644
--- a/target-i386/kvm.c
+++ b/target-i386/kvm.c
@@ -36,7 +36,6 @@
#include <asm/hyperv.h>
#include "hw/pci/pci.h"
#include "migration/migration.h"
-#include "qapi/qmp/qerror.h"
#include "exec/memattrs.h"
//#define DEBUG_KVM
diff --git a/ui/vnc.c b/ui/vnc.c
index af165845a3..2ffd9e500f 100644
--- a/ui/vnc.c
+++ b/ui/vnc.c
@@ -34,6 +34,7 @@
#include "qemu/timer.h"
#include "qemu/acl.h"
#include "qemu/config-file.h"
+#include "qapi/qmp/qerror.h"
#include "qapi/qmp/types.h"
#include "qmp-commands.h"
#include "qemu/osdep.h"
diff --git a/util/qemu-config.c b/util/qemu-config.c
index 6cfdd7204a..5fcfd0e6ac 100644
--- a/util/qemu-config.c
+++ b/util/qemu-config.c
@@ -2,7 +2,6 @@
#include "qemu/error-report.h"
#include "qemu/option.h"
#include "qemu/config-file.h"
-#include "qapi/qmp/qerror.h"
#include "qapi/error.h"
#include "qmp-commands.h"