aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2018-02-01 12:18:39 +0100
committerMarkus Armbruster <armbru@redhat.com>2018-02-09 13:52:15 +0100
commit452fcdbc49c59884c8c284268d64baa24fea11e1 (patch)
tree8c057e6a77d4a83befd74d8a6a6e596f4db7d2d0
parent47e6b297e76007c04a1e9c492006fe093d932cd9 (diff)
Include qapi/qmp/qdict.h exactly where needed
This cleanup makes the number of objects depending on qapi/qmp/qdict.h drop from 4550 (out of 4743) to 368 in my "build everything" tree. For qapi/qmp/qobject.h, the number drops from 4552 to 390. While there, separate #include from file comment with a blank line. Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20180201111846.21846-13-armbru@redhat.com>
-rw-r--r--block.c1
-rw-r--r--block/crypto.c1
-rw-r--r--block/curl.c2
-rw-r--r--block/file-posix.c1
-rw-r--r--block/file-win32.c1
-rw-r--r--block/gluster.c1
-rw-r--r--block/iscsi.c1
-rw-r--r--block/qapi.c1
-rw-r--r--block/qcow.c2
-rw-r--r--block/rbd.c1
-rw-r--r--block/snapshot.c1
-rw-r--r--block/ssh.c1
-rw-r--r--block/vvfat.c2
-rw-r--r--blockdev.c1
-rw-r--r--device-hotplug.c1
-rw-r--r--hmp.c1
-rw-r--r--hmp.h1
-rw-r--r--hw/pci/pcie_aer.c1
-rw-r--r--hw/s390x/s390-skeys.c1
-rw-r--r--hw/s390x/s390-stattrib.c1
-rw-r--r--hw/usb/xen-usb.c1
-rw-r--r--include/block/block.h1
-rw-r--r--include/block/dirty-bitmap.h1
-rw-r--r--include/hw/block/block.h1
-rw-r--r--include/hw/block/fdc.h1
-rw-r--r--include/hw/loader.h1
-rw-r--r--include/migration/colo.h1
-rw-r--r--include/migration/failover.h1
-rw-r--r--include/monitor/monitor.h1
-rw-r--r--include/net/net.h2
-rw-r--r--include/net/slirp.h1
-rw-r--r--include/qapi/qmp-event.h1
-rw-r--r--include/qapi/qmp/dispatch.h2
-rw-r--r--include/qemu/config-file.h1
-rw-r--r--include/qemu/option.h1
-rw-r--r--include/qemu/throttle.h1
-rw-r--r--include/qom/object_interfaces.h1
-rw-r--r--include/scsi/pr-manager.h1
-rw-r--r--include/sysemu/arch_init.h1
-rw-r--r--include/ui/console.h1
-rw-r--r--migration/ram.h1
-rw-r--r--monitor.c1
-rw-r--r--net/net.c1
-rw-r--r--net/slirp.c2
-rw-r--r--net/tap_int.h1
-rw-r--r--qapi/qmp-dispatch.c1
-rw-r--r--qapi/qmp-event.c1
-rw-r--r--qapi/qobject-input-visitor.c1
-rw-r--r--qapi/qobject-output-visitor.c1
-rw-r--r--qdev-monitor.c1
-rw-r--r--qemu-img.c2
-rw-r--r--qemu-io.c2
-rw-r--r--qemu-nbd.c1
-rw-r--r--qga/main.c1
-rw-r--r--qmp.c1
-rw-r--r--qobject/json-parser.c1
-rw-r--r--qobject/qjson.c1
-rw-r--r--qom/object_interfaces.c1
-rw-r--r--scripts/qapi-commands.py2
-rw-r--r--scripts/qapi-event.py2
-rw-r--r--target/i386/cpu.c1
-rw-r--r--target/i386/monitor.c2
-rw-r--r--target/s390x/cpu_models.c1
-rw-r--r--tests/ahci-test.c1
-rw-r--r--tests/check-qobject.c1
-rw-r--r--tests/cpu-plug-test.c1
-rw-r--r--tests/drive_del-test.c1
-rw-r--r--tests/libqos/libqos.c1
-rw-r--r--tests/libqos/pci-pc.c2
-rw-r--r--tests/libqtest.c1
-rw-r--r--tests/libqtest.h2
-rw-r--r--tests/migration-test.c1
-rw-r--r--tests/numa-test.c1
-rw-r--r--tests/pvpanic-test.c1
-rw-r--r--tests/q35-test.c1
-rw-r--r--tests/qmp-test.c1
-rw-r--r--tests/qom-test.c1
-rw-r--r--tests/tco-test.c2
-rw-r--r--tests/test-char.c1
-rw-r--r--tests/test-keyval.c1
-rw-r--r--tests/test-netfilter.c1
-rw-r--r--tests/test-qemu-opts.c1
-rw-r--r--tests/test-qga.c1
-rw-r--r--tests/test-qmp-event.c1
-rw-r--r--tests/test-qobject-input-visitor.c1
-rw-r--r--tests/test-qobject-output-visitor.c1
-rw-r--r--tests/test-replication.c1
-rw-r--r--tests/tmp105-test.c1
-rw-r--r--tests/vhost-user-test.c1
-rw-r--r--tests/virtio-net-test.c1
-rw-r--r--tests/vmgenid-test.c1
-rw-r--r--tests/wdt_ib700-test.c1
-rw-r--r--ui/input.c1
-rw-r--r--util/keyval.c1
-rw-r--r--util/qemu-config.c1
95 files changed, 92 insertions, 17 deletions
diff --git a/block.c b/block.c
index a97f709252..367641ef4f 100644
--- a/block.c
+++ b/block.c
@@ -31,6 +31,7 @@
#include "module_block.h"
#include "qemu/module.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qbool.h"
#include "qapi/qmp/qjson.h"
diff --git a/block/crypto.c b/block/crypto.c
index 60ddf8623e..2626f8ae3a 100644
--- a/block/crypto.c
+++ b/block/crypto.c
@@ -24,6 +24,7 @@
#include "sysemu/block-backend.h"
#include "crypto/block.h"
#include "qapi/opts-visitor.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qobject-input-visitor.h"
#include "qapi-visit.h"
#include "qapi/error.h"
diff --git a/block/curl.c b/block/curl.c
index cd578d3d14..eafa97cd72 100644
--- a/block/curl.c
+++ b/block/curl.c
@@ -21,12 +21,14 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
+
#include "qemu/osdep.h"
#include "qapi/error.h"
#include "qemu-common.h"
#include "qemu/error-report.h"
#include "block/block_int.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qstring.h"
#include "crypto/secret.h"
#include <curl/curl.h>
diff --git a/block/file-posix.c b/block/file-posix.c
index 36ee89e940..9422ad529c 100644
--- a/block/file-posix.c
+++ b/block/file-posix.c
@@ -31,6 +31,7 @@
#include "block/thread-pool.h"
#include "qemu/iov.h"
#include "block/raw-aio.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qstring.h"
#include "scsi/pr-manager.h"
diff --git a/block/file-win32.c b/block/file-win32.c
index 9e02214a69..2f1da48e71 100644
--- a/block/file-win32.c
+++ b/block/file-win32.c
@@ -30,6 +30,7 @@
#include "trace.h"
#include "block/thread-pool.h"
#include "qemu/iov.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qstring.h"
#include <windows.h>
#include <winioctl.h>
diff --git a/block/gluster.c b/block/gluster.c
index 0f4265a3a4..097b6930a5 100644
--- a/block/gluster.c
+++ b/block/gluster.c
@@ -11,6 +11,7 @@
#include <glusterfs/api/glfs.h>
#include "block/block_int.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qerror.h"
#include "qemu/uri.h"
#include "qemu/error-report.h"
diff --git a/block/iscsi.c b/block/iscsi.c
index 9a1bf43cbc..8edd480f92 100644
--- a/block/iscsi.c
+++ b/block/iscsi.c
@@ -39,6 +39,7 @@
#include "qemu/uuid.h"
#include "qmp-commands.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qstring.h"
#include "crypto/secret.h"
#include "scsi/utils.h"
diff --git a/block/qapi.c b/block/qapi.c
index 12a8cb5a82..1fdeb1ef2f 100644
--- a/block/qapi.c
+++ b/block/qapi.c
@@ -32,6 +32,7 @@
#include "qapi/error.h"
#include "qapi/qobject-output-visitor.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
#include "qapi/qmp/qnum.h"
#include "qapi/qmp/qstring.h"
diff --git a/block/qcow.c b/block/qcow.c
index 369241aae8..0b32c04cd0 100644
--- a/block/qcow.c
+++ b/block/qcow.c
@@ -21,6 +21,7 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
+
#include "qemu/osdep.h"
#include "qapi/error.h"
#include "qemu-common.h"
@@ -30,6 +31,7 @@
#include "qemu/module.h"
#include "qemu/bswap.h"
#include <zlib.h>
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qstring.h"
#include "crypto/block.h"
#include "migration/blocker.h"
diff --git a/block/rbd.c b/block/rbd.c
index 76b9e83cea..42be5ed49d 100644
--- a/block/rbd.c
+++ b/block/rbd.c
@@ -20,6 +20,7 @@
#include "crypto/secret.h"
#include "qemu/cutils.h"
#include "qapi/qmp/qstring.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qjson.h"
#include "qapi/qmp/qlist.h"
diff --git a/block/snapshot.c b/block/snapshot.c
index 8cb70dbad5..9294a9fcc4 100644
--- a/block/snapshot.c
+++ b/block/snapshot.c
@@ -26,6 +26,7 @@
#include "block/snapshot.h"
#include "block/block_int.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qstring.h"
diff --git a/block/ssh.c b/block/ssh.c
index 8890a0c4ba..91f5f4c3c9 100644
--- a/block/ssh.c
+++ b/block/ssh.c
@@ -34,6 +34,7 @@
#include "qemu/sockets.h"
#include "qemu/uri.h"
#include "qapi-visit.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qstring.h"
#include "qapi/qobject-input-visitor.h"
#include "qapi/qobject-output-visitor.h"
diff --git a/block/vvfat.c b/block/vvfat.c
index a690595f2c..93e76580b0 100644
--- a/block/vvfat.c
+++ b/block/vvfat.c
@@ -22,6 +22,7 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
+
#include "qemu/osdep.h"
#include <dirent.h>
#include "qapi/error.h"
@@ -30,6 +31,7 @@
#include "qemu/bswap.h"
#include "migration/blocker.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qstring.h"
#include "qemu/cutils.h"
#include "qemu/error-report.h"
diff --git a/blockdev.c b/blockdev.c
index 90ef3166de..bdbdeae7e4 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -40,6 +40,7 @@
#include "qemu/error-report.h"
#include "qemu/option.h"
#include "qemu/config-file.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qnum.h"
#include "qapi/qmp/qstring.h"
#include "qapi-visit.h"
diff --git a/device-hotplug.c b/device-hotplug.c
index 126f73c676..b10e8cc6d4 100644
--- a/device-hotplug.c
+++ b/device-hotplug.c
@@ -27,6 +27,7 @@
#include "hw/boards.h"
#include "sysemu/block-backend.h"
#include "sysemu/blockdev.h"
+#include "qapi/qmp/qdict.h"
#include "qemu/config-file.h"
#include "sysemu/sysemu.h"
#include "monitor/monitor.h"
diff --git a/hmp.c b/hmp.c
index 13550b0191..7870d6a300 100644
--- a/hmp.c
+++ b/hmp.c
@@ -29,6 +29,7 @@
#include "monitor/qdev.h"
#include "qapi/error.h"
#include "qapi/opts-visitor.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qerror.h"
#include "qapi/string-input-visitor.h"
#include "qapi/string-output-visitor.h"
diff --git a/hmp.h b/hmp.h
index 62c969caa3..1143db44a7 100644
--- a/hmp.h
+++ b/hmp.h
@@ -16,7 +16,6 @@
#include "qemu-common.h"
#include "qemu/readline.h"
-#include "qapi/qmp/qdict.h"
void hmp_info_name(Monitor *mon, const QDict *qdict);
void hmp_info_version(Monitor *mon, const QDict *qdict);
diff --git a/hw/pci/pcie_aer.c b/hw/pci/pcie_aer.c
index 071e5e9bbb..0b55392fe7 100644
--- a/hw/pci/pcie_aer.c
+++ b/hw/pci/pcie_aer.c
@@ -20,6 +20,7 @@
#include "qemu/osdep.h"
#include "sysemu/sysemu.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qjson.h"
#include "monitor/monitor.h"
#include "hw/pci/pci_bridge.h"
diff --git a/hw/s390x/s390-skeys.c b/hw/s390x/s390-skeys.c
index fd994f86b1..bdb6c18a0f 100644
--- a/hw/s390x/s390-skeys.c
+++ b/hw/s390x/s390-skeys.c
@@ -14,6 +14,7 @@
#include "qmp-commands.h"
#include "hw/s390x/storage-keys.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qemu/error-report.h"
#include "sysemu/kvm.h"
#include "migration/register.h"
diff --git a/hw/s390x/s390-stattrib.c b/hw/s390x/s390-stattrib.c
index c6c06b2780..a1d2135a60 100644
--- a/hw/s390x/s390-stattrib.c
+++ b/hw/s390x/s390-stattrib.c
@@ -18,6 +18,7 @@
#include "qemu/error-report.h"
#include "exec/ram_addr.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#define CMMA_BLOCK_SIZE (1 << 10)
diff --git a/hw/usb/xen-usb.c b/hw/usb/xen-usb.c
index 584a6f2442..3b678685e1 100644
--- a/hw/usb/xen-usb.c
+++ b/hw/usb/xen-usb.c
@@ -30,6 +30,7 @@
#include "hw/xen/xen_backend.h"
#include "monitor/qdev.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qstring.h"
#include "hw/xen/io/ring.h"
diff --git a/include/block/block.h b/include/block/block.h
index 549e4c4618..47e2910db2 100644
--- a/include/block/block.h
+++ b/include/block/block.h
@@ -2,6 +2,7 @@
#define BLOCK_H
#include "block/aio.h"
+#include "qapi-types.h"
#include "qemu/iov.h"
#include "qemu/option.h"
#include "qemu/coroutine.h"
diff --git a/include/block/dirty-bitmap.h b/include/block/dirty-bitmap.h
index a591c27213..3da8486ab1 100644
--- a/include/block/dirty-bitmap.h
+++ b/include/block/dirty-bitmap.h
@@ -2,6 +2,7 @@
#define BLOCK_DIRTY_BITMAP_H
#include "qemu-common.h"
+#include "qapi-types.h"
#include "qemu/hbitmap.h"
BdrvDirtyBitmap *bdrv_create_dirty_bitmap(BlockDriverState *bs,
diff --git a/include/hw/block/block.h b/include/hw/block/block.h
index 64b9298829..f532d10e35 100644
--- a/include/hw/block/block.h
+++ b/include/hw/block/block.h
@@ -12,6 +12,7 @@
#define HW_BLOCK_H
#include "qemu-common.h"
+#include "qapi-types.h"
/* Configuration */
diff --git a/include/hw/block/fdc.h b/include/hw/block/fdc.h
index 1749dabf25..68a0c904ea 100644
--- a/include/hw/block/fdc.h
+++ b/include/hw/block/fdc.h
@@ -2,6 +2,7 @@
#define HW_FDC_H
#include "qemu-common.h"
+#include "qapi-types.h"
/* fdc.c */
#define MAX_FD 2
diff --git a/include/hw/loader.h b/include/hw/loader.h
index 355fe0f5a2..5edbe02b1c 100644
--- a/include/hw/loader.h
+++ b/include/hw/loader.h
@@ -1,6 +1,5 @@
#ifndef LOADER_H
#define LOADER_H
-#include "qapi/qmp/qdict.h"
#include "hw/nvram/fw_cfg.h"
/* loader.c */
diff --git a/include/migration/colo.h b/include/migration/colo.h
index ff9874ea16..50ace16205 100644
--- a/include/migration/colo.h
+++ b/include/migration/colo.h
@@ -14,6 +14,7 @@
#define QEMU_COLO_H
#include "qemu-common.h"
+#include "qapi-types.h"
void colo_info_init(void);
diff --git a/include/migration/failover.h b/include/migration/failover.h
index 9283d602e6..ad91ef2381 100644
--- a/include/migration/failover.h
+++ b/include/migration/failover.h
@@ -14,6 +14,7 @@
#define QEMU_FAILOVER_H
#include "qemu-common.h"
+#include "qapi-types.h"
void failover_init_state(void);
FailoverStatus failover_set_state(FailoverStatus old_state,
diff --git a/include/monitor/monitor.h b/include/monitor/monitor.h
index 83ea4a1aaf..ad64ad8e68 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/qdict.h"
#include "block/block.h"
#include "qemu/readline.h"
diff --git a/include/net/net.h b/include/net/net.h
index eefb259e0a..71f1119bc9 100644
--- a/include/net/net.h
+++ b/include/net/net.h
@@ -3,7 +3,7 @@
#include "qemu/queue.h"
#include "qemu-common.h"
-#include "qapi/qmp/qdict.h"
+#include "qapi-types.h"
#include "qemu/option.h"
#include "net/queue.h"
#include "migration/vmstate.h"
diff --git a/include/net/slirp.h b/include/net/slirp.h
index 865d2fca36..9a492b84a4 100644
--- a/include/net/slirp.h
+++ b/include/net/slirp.h
@@ -25,7 +25,6 @@
#define QEMU_NET_SLIRP_H
#include "qemu-common.h"
-#include "qapi/qmp/qdict.h"
#include "qemu/option.h"
#ifdef CONFIG_SLIRP
diff --git a/include/qapi/qmp-event.h b/include/qapi/qmp-event.h
index 40fe3cbc12..0c87ad833e 100644
--- a/include/qapi/qmp-event.h
+++ b/include/qapi/qmp-event.h
@@ -14,7 +14,6 @@
#ifndef QMP_EVENT_H
#define QMP_EVENT_H
-#include "qapi/qmp/qdict.h"
typedef void (*QMPEventFuncEmit)(unsigned event, QDict *dict, Error **errp);
diff --git a/include/qapi/qmp/dispatch.h b/include/qapi/qmp/dispatch.h
index 47a0ff348b..1e694b5ecf 100644
--- a/include/qapi/qmp/dispatch.h
+++ b/include/qapi/qmp/dispatch.h
@@ -14,7 +14,7 @@
#ifndef QAPI_QMP_DISPATCH_H
#define QAPI_QMP_DISPATCH_H
-#include "qapi/qmp/qdict.h"
+#include "qemu/queue.h"
typedef void (QmpCommandFunc)(QDict *, QObject **, Error **);
diff --git a/include/qemu/config-file.h b/include/qemu/config-file.h
index c80d5c8a33..449e631c86 100644
--- a/include/qemu/config-file.h
+++ b/include/qemu/config-file.h
@@ -2,7 +2,6 @@
#define QEMU_CONFIG_FILE_H
#include "qemu/option.h"
-#include "qapi/qmp/qdict.h"
QemuOptsList *qemu_find_opts(const char *group);
QemuOptsList *qemu_find_opts_err(const char *group, Error **errp);
diff --git a/include/qemu/option.h b/include/qemu/option.h
index a88c5f02b1..b127fb6db6 100644
--- a/include/qemu/option.h
+++ b/include/qemu/option.h
@@ -27,7 +27,6 @@
#define QEMU_OPTION_H
#include "qemu/queue.h"
-#include "qapi/qmp/qdict.h"
const char *get_opt_name(char *buf, int buf_size, const char *p, char delim);
const char *get_opt_value(char *buf, int buf_size, const char *p);
diff --git a/include/qemu/throttle.h b/include/qemu/throttle.h
index 8c93237866..03d45f44f8 100644
--- a/include/qemu/throttle.h
+++ b/include/qemu/throttle.h
@@ -26,6 +26,7 @@
#define THROTTLE_H
#include "qemu-common.h"
+#include "qapi-types.h"
#include "qemu/timer.h"
#define THROTTLE_VALUE_MAX 1000000000000000LL
diff --git a/include/qom/object_interfaces.h b/include/qom/object_interfaces.h
index d23e11bc53..4d513fb329 100644
--- a/include/qom/object_interfaces.h
+++ b/include/qom/object_interfaces.h
@@ -2,7 +2,6 @@
#define OBJECT_INTERFACES_H
#include "qom/object.h"
-#include "qapi/qmp/qdict.h"
#include "qapi/visitor.h"
#define TYPE_USER_CREATABLE "user-creatable"
diff --git a/include/scsi/pr-manager.h b/include/scsi/pr-manager.h
index b2b37d63bc..5d2f13a5e4 100644
--- a/include/scsi/pr-manager.h
+++ b/include/scsi/pr-manager.h
@@ -2,7 +2,6 @@
#define PR_MANAGER_H
#include "qom/object.h"
-#include "qapi/qmp/qdict.h"
#include "qapi/visitor.h"
#include "qom/object_interfaces.h"
#include "block/aio.h"
diff --git a/include/sysemu/arch_init.h b/include/sysemu/arch_init.h
index 4b88f99060..28f713eae2 100644
--- a/include/sysemu/arch_init.h
+++ b/include/sysemu/arch_init.h
@@ -1,6 +1,7 @@
#ifndef QEMU_ARCH_INIT_H
#define QEMU_ARCH_INIT_H
+#include "qapi-types.h"
#include "qemu/option.h"
enum {
diff --git a/include/ui/console.h b/include/ui/console.h
index f3a1ec243d..12fef80923 100644
--- a/include/ui/console.h
+++ b/include/ui/console.h
@@ -3,7 +3,6 @@
#include "ui/qemu-pixman.h"
#include "qom/object.h"
-#include "qapi/qmp/qdict.h"
#include "qemu/notify.h"
#include "qemu/error-report.h"
diff --git a/migration/ram.h b/migration/ram.h
index 64d81e9f1d..f3a227b4fc 100644
--- a/migration/ram.h
+++ b/migration/ram.h
@@ -30,6 +30,7 @@
#define QEMU_MIGRATION_RAM_H
#include "qemu-common.h"
+#include "qapi-types.h"
#include "exec/cpu-common.h"
extern MigrationStats ram_counters;
diff --git a/monitor.c b/monitor.c
index 20f7b159b3..a22d911087 100644
--- a/monitor.c
+++ b/monitor.c
@@ -52,6 +52,7 @@
#include "sysemu/hw_accel.h"
#include "qemu/acl.h"
#include "sysemu/tpm.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qbool.h"
#include "qapi/qmp/qnum.h"
diff --git a/net/net.c b/net/net.c
index b36449dd65..7a22ca74e2 100644
--- a/net/net.c
+++ b/net/net.c
@@ -34,6 +34,7 @@
#include "monitor/monitor.h"
#include "qemu-common.h"
#include "qemu/help_option.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qerror.h"
#include "qemu/error-report.h"
#include "qemu/sockets.h"
diff --git a/net/slirp.c b/net/slirp.c
index 7044d292c8..8991816bbf 100644
--- a/net/slirp.c
+++ b/net/slirp.c
@@ -21,6 +21,7 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
+
#include "qemu/osdep.h"
#include "net/slirp.h"
@@ -41,6 +42,7 @@
#include "sysemu/sysemu.h"
#include "qemu/cutils.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
static int get_str_sep(char *buf, int buf_size, const char **pp, int sep)
{
diff --git a/net/tap_int.h b/net/tap_int.h
index e3a14d5dda..ae6888f74a 100644
--- a/net/tap_int.h
+++ b/net/tap_int.h
@@ -27,6 +27,7 @@
#define NET_TAP_INT_H
#include "qemu-common.h"
+#include "qapi-types.h"
int tap_open(char *ifname, int ifname_size, int *vnet_hdr,
int vnet_hdr_required, int mq_required, Error **errp);
diff --git a/qapi/qmp-dispatch.c b/qapi/qmp-dispatch.c
index 92f957f40e..e31ac4be1f 100644
--- a/qapi/qmp-dispatch.c
+++ b/qapi/qmp-dispatch.c
@@ -15,6 +15,7 @@
#include "qapi/error.h"
#include "qapi/qmp/dispatch.h"
#include "qapi/qmp/json-parser.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qjson.h"
static QDict *qmp_dispatch_check_obj(const QObject *request, Error **errp)
diff --git a/qapi/qmp-event.c b/qapi/qmp-event.c
index ba3029cc89..9d7e88e84a 100644
--- a/qapi/qmp-event.c
+++ b/qapi/qmp-event.c
@@ -16,6 +16,7 @@
#include "qemu-common.h"
#include "qapi/qmp-event.h"
#include "qapi/qmp/qstring.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qjson.h"
static QMPEventFuncEmit qmp_emit;
diff --git a/qapi/qobject-input-visitor.c b/qapi/qobject-input-visitor.c
index 3e235a1eee..3566eed365 100644
--- a/qapi/qobject-input-visitor.c
+++ b/qapi/qobject-input-visitor.c
@@ -21,6 +21,7 @@
#include "qemu-common.h"
#include "qapi/qmp/qjson.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qerror.h"
#include "qapi/qmp/qlist.h"
#include "qapi/qmp/qnull.h"
diff --git a/qapi/qobject-output-visitor.c b/qapi/qobject-output-visitor.c
index 52634b9725..7c3b42cfe2 100644
--- a/qapi/qobject-output-visitor.c
+++ b/qapi/qobject-output-visitor.c
@@ -18,6 +18,7 @@
#include "qemu/queue.h"
#include "qemu-common.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
#include "qapi/qmp/qnull.h"
#include "qapi/qmp/qnum.h"
diff --git a/qdev-monitor.c b/qdev-monitor.c
index 0aa8a6c60b..a954c2192b 100644
--- a/qdev-monitor.c
+++ b/qdev-monitor.c
@@ -25,6 +25,7 @@
#include "qmp-commands.h"
#include "sysemu/arch_init.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.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 8023233c3d..c6bcfcd83e 100644
--- a/qemu-img.c
+++ b/qemu-img.c
@@ -21,6 +21,7 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
+
#include "qemu/osdep.h"
#include <getopt.h>
@@ -30,6 +31,7 @@
#include "qapi/qobject-output-visitor.h"
#include "qapi/qmp/qjson.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qemu/cutils.h"
#include "qemu/config-file.h"
#include "qemu/option.h"
diff --git a/qemu-io.c b/qemu-io.c
index c70bde3eb1..2e5737ce9c 100644
--- a/qemu-io.c
+++ b/qemu-io.c
@@ -7,6 +7,7 @@
* This work is licensed under the terms of the GNU GPL, version 2 or later.
* See the COPYING file in the top-level directory.
*/
+
#include "qemu/osdep.h"
#include <getopt.h>
#include <libgen.h>
@@ -21,6 +22,7 @@
#include "qemu/log.h"
#include "qapi/qmp/qstring.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qom/object_interfaces.h"
#include "sysemu/block-backend.h"
#include "block/block_int.h"
diff --git a/qemu-nbd.c b/qemu-nbd.c
index 3723493be1..6ff8ef41e9 100644
--- a/qemu-nbd.c
+++ b/qemu-nbd.c
@@ -34,6 +34,7 @@
#include "qemu/log.h"
#include "qemu/systemd.h"
#include "block/snapshot.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qstring.h"
#include "qom/object_interfaces.h"
#include "io/channel-socket.h"
diff --git a/qga/main.c b/qga/main.c
index 804cc4c1a0..72406a3c23 100644
--- a/qga/main.c
+++ b/qga/main.c
@@ -20,6 +20,7 @@
#endif
#include "qapi/qmp/json-streamer.h"
#include "qapi/qmp/json-parser.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qjson.h"
#include "qga/guest-agent-core.h"
#include "qemu/module.h"
diff --git a/qmp.c b/qmp.c
index f87de2bc26..1b750293e4 100644
--- a/qmp.c
+++ b/qmp.c
@@ -31,6 +31,7 @@
#include "sysemu/block-backend.h"
#include "qom/qom-qobject.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qerror.h"
#include "qapi/qobject-input-visitor.h"
#include "hw/boards.h"
diff --git a/qobject/json-parser.c b/qobject/json-parser.c
index ee0cbba6a5..b724562415 100644
--- a/qobject/json-parser.c
+++ b/qobject/json-parser.c
@@ -16,6 +16,7 @@
#include "qapi/error.h"
#include "qemu-common.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
#include "qapi/qmp/qnull.h"
#include "qapi/qmp/qnum.h"
diff --git a/qobject/qjson.c b/qobject/qjson.c
index 527b5bb571..77f796bbee 100644
--- a/qobject/qjson.c
+++ b/qobject/qjson.c
@@ -18,6 +18,7 @@
#include "qapi/qmp/json-streamer.h"
#include "qapi/qmp/qjson.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
#include "qapi/qmp/qnum.h"
#include "qemu/unicode.h"
diff --git a/qom/object_interfaces.c b/qom/object_interfaces.c
index 6824a88caa..2719df3bae 100644
--- a/qom/object_interfaces.c
+++ b/qom/object_interfaces.c
@@ -1,5 +1,6 @@
#include "qemu/osdep.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qom/object_interfaces.h"
#include "qemu/module.h"
#include "qapi-visit.h"
diff --git a/scripts/qapi-commands.py b/scripts/qapi-commands.py
index 26c56c5062..f89d748ba4 100644
--- a/scripts/qapi-commands.py
+++ b/scripts/qapi-commands.py
@@ -294,6 +294,7 @@ fdef.write(mcgen('''
#include "qemu-common.h"
#include "qemu/module.h"
#include "qapi/visitor.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qobject-output-visitor.h"
#include "qapi/qobject-input-visitor.h"
#include "qapi/dealloc-visitor.h"
@@ -307,7 +308,6 @@ fdef.write(mcgen('''
fdecl.write(mcgen('''
#include "%(prefix)sqapi-types.h"
-#include "qapi/qmp/qdict.h"
#include "qapi/qmp/dispatch.h"
void %(c_prefix)sqmp_init_marshal(QmpCommandList *cmds);
diff --git a/scripts/qapi-event.py b/scripts/qapi-event.py
index 9d7134658d..c710968dc2 100644
--- a/scripts/qapi-event.py
+++ b/scripts/qapi-event.py
@@ -210,6 +210,7 @@ fdef.write(mcgen('''
#include "%(prefix)sqapi-event.h"
#include "%(prefix)sqapi-visit.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qobject-output-visitor.h"
#include "qapi/qmp-event.h"
@@ -218,7 +219,6 @@ fdef.write(mcgen('''
fdecl.write(mcgen('''
#include "qapi/util.h"
-#include "qapi/qmp/qdict.h"
#include "%(prefix)sqapi-types.h"
''',
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index 5cb63eae41..b5e431e769 100644
--- a/target/i386/cpu.c
+++ b/target/i386/cpu.c
@@ -31,6 +31,7 @@
#include "qemu/option.h"
#include "qemu/config-file.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qerror.h"
#include "qapi-visit.h"
diff --git a/target/i386/monitor.c b/target/i386/monitor.c
index 75e155ffb1..75429129fd 100644
--- a/target/i386/monitor.c
+++ b/target/i386/monitor.c
@@ -21,10 +21,12 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
+
#include "qemu/osdep.h"
#include "cpu.h"
#include "monitor/monitor.h"
#include "monitor/hmp-target.h"
+#include "qapi/qmp/qdict.h"
#include "hw/i386/pc.h"
#include "sysemu/kvm.h"
#include "hmp.h"
diff --git a/target/s390x/cpu_models.c b/target/s390x/cpu_models.c
index 212a5f0697..27201c4f91 100644
--- a/target/s390x/cpu_models.c
+++ b/target/s390x/cpu_models.c
@@ -21,6 +21,7 @@
#include "qapi/qmp/qerror.h"
#include "qapi/qobject-input-visitor.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#ifndef CONFIG_USER_ONLY
#include "sysemu/arch_init.h"
#endif
diff --git a/tests/ahci-test.c b/tests/ahci-test.c
index 3934e62ef7..7aa5af428c 100644
--- a/tests/ahci-test.c
+++ b/tests/ahci-test.c
@@ -31,6 +31,7 @@
#include "libqos/pci-pc.h"
#include "qemu-common.h"
+#include "qapi/qmp/qdict.h"
#include "qemu/host-utils.h"
#include "hw/pci/pci_ids.h"
diff --git a/tests/check-qobject.c b/tests/check-qobject.c
index 885d0e3de6..7a3670643c 100644
--- a/tests/check-qobject.c
+++ b/tests/check-qobject.c
@@ -9,6 +9,7 @@
#include "qemu/osdep.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
#include "qapi/qmp/qnull.h"
#include "qapi/qmp/qnum.h"
diff --git a/tests/cpu-plug-test.c b/tests/cpu-plug-test.c
index 65456c9e37..8b5ab1fd02 100644
--- a/tests/cpu-plug-test.c
+++ b/tests/cpu-plug-test.c
@@ -11,6 +11,7 @@
#include "qemu-common.h"
#include "libqtest.h"
+#include "qapi/qmp/qdict.h"
struct PlugTestData {
char *machine;
diff --git a/tests/drive_del-test.c b/tests/drive_del-test.c
index c9ac997555..313030a14c 100644
--- a/tests/drive_del-test.c
+++ b/tests/drive_del-test.c
@@ -13,6 +13,7 @@
#include "qemu/osdep.h"
#include "libqtest.h"
#include "libqos/virtio.h"
+#include "qapi/qmp/qdict.h"
static void drive_add(void)
{
diff --git a/tests/libqos/libqos.c b/tests/libqos/libqos.c
index 991bc1aec2..306d4c06de 100644
--- a/tests/libqos/libqos.c
+++ b/tests/libqos/libqos.c
@@ -4,6 +4,7 @@
#include "libqtest.h"
#include "libqos/libqos.h"
#include "libqos/pci.h"
+#include "qapi/qmp/qdict.h"
/*** Test Setup & Teardown ***/
diff --git a/tests/libqos/pci-pc.c b/tests/libqos/pci-pc.c
index ded1c54c06..cd4e20e1ea 100644
--- a/tests/libqos/pci-pc.c
+++ b/tests/libqos/pci-pc.c
@@ -13,7 +13,7 @@
#include "qemu/osdep.h"
#include "libqtest.h"
#include "libqos/pci-pc.h"
-
+#include "qapi/qmp/qdict.h"
#include "hw/pci/pci_regs.h"
#include "qemu-common.h"
diff --git a/tests/libqtest.c b/tests/libqtest.c
index 16d60818a7..b65374c634 100644
--- a/tests/libqtest.c
+++ b/tests/libqtest.c
@@ -24,6 +24,7 @@
#include "qapi/error.h"
#include "qapi/qmp/json-parser.h"
#include "qapi/qmp/json-streamer.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qjson.h"
#include "qapi/qmp/qlist.h"
diff --git a/tests/libqtest.h b/tests/libqtest.h
index fe7847cbd5..811169453a 100644
--- a/tests/libqtest.h
+++ b/tests/libqtest.h
@@ -17,8 +17,6 @@
#ifndef LIBQTEST_H
#define LIBQTEST_H
-#include "qapi/qmp/qdict.h"
-
typedef struct QTestState QTestState;
extern QTestState *global_qtest;
diff --git a/tests/migration-test.c b/tests/migration-test.c
index 9efad95749..d0abad40f5 100644
--- a/tests/migration-test.c
+++ b/tests/migration-test.c
@@ -13,6 +13,7 @@
#include "qemu/osdep.h"
#include "libqtest.h"
+#include "qapi/qmp/qdict.h"
#include "qemu/option.h"
#include "qemu/range.h"
#include "qemu/sockets.h"
diff --git a/tests/numa-test.c b/tests/numa-test.c
index 8158854e17..68aca9cb38 100644
--- a/tests/numa-test.c
+++ b/tests/numa-test.c
@@ -11,6 +11,7 @@
#include "qemu/osdep.h"
#include "libqtest.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
static char *make_cli(const char *generic_cli, const char *test_cli)
diff --git a/tests/pvpanic-test.c b/tests/pvpanic-test.c
index 71ebb5c02c..ebdf32c2e2 100644
--- a/tests/pvpanic-test.c
+++ b/tests/pvpanic-test.c
@@ -9,6 +9,7 @@
#include "qemu/osdep.h"
#include "libqtest.h"
+#include "qapi/qmp/qdict.h"
static void test_panic(void)
{
diff --git a/tests/q35-test.c b/tests/q35-test.c
index f98bed7a2d..187d68fb7e 100644
--- a/tests/q35-test.c
+++ b/tests/q35-test.c
@@ -14,6 +14,7 @@
#include "libqos/pci.h"
#include "libqos/pci-pc.h"
#include "hw/pci-host/q35.h"
+#include "qapi/qmp/qdict.h"
#define TSEG_SIZE_TEST_GUEST_RAM_MBYTES 128
diff --git a/tests/qmp-test.c b/tests/qmp-test.c
index cc9661af47..908f9b981f 100644
--- a/tests/qmp-test.c
+++ b/tests/qmp-test.c
@@ -14,6 +14,7 @@
#include "libqtest.h"
#include "qapi-visit.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
#include "qapi/qobject-input-visitor.h"
#include "qapi/util.h"
diff --git a/tests/qom-test.c b/tests/qom-test.c
index 847703cb14..9dab7ac61e 100644
--- a/tests/qom-test.c
+++ b/tests/qom-test.c
@@ -10,6 +10,7 @@
#include "qemu/osdep.h"
#include "qemu-common.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
#include "qemu/cutils.h"
#include "libqtest.h"
diff --git a/tests/tco-test.c b/tests/tco-test.c
index 2616d33c29..8ab43d742a 100644
--- a/tests/tco-test.c
+++ b/tests/tco-test.c
@@ -6,11 +6,13 @@
* This work is licensed under the terms of the GNU GPL, version 2 or later.
* See the COPYING file in the top-level directory.
*/
+
#include "qemu/osdep.h"
#include "libqtest.h"
#include "libqos/pci.h"
#include "libqos/pci-pc.h"
+#include "qapi/qmp/qdict.h"
#include "hw/pci/pci_regs.h"
#include "hw/i386/ich9.h"
#include "hw/acpi/ich9.h"
diff --git a/tests/test-char.c b/tests/test-char.c
index 911e3f6e8d..54e68a1ad2 100644
--- a/tests/test-char.c
+++ b/tests/test-char.c
@@ -8,6 +8,7 @@
#include "chardev/char-mux.h"
#include "sysemu/sysemu.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qom/qom-qobject.h"
#include "qmp-commands.h"
diff --git a/tests/test-keyval.c b/tests/test-keyval.c
index d0c4bf2b9d..94eb4df28d 100644
--- a/tests/test-keyval.c
+++ b/tests/test-keyval.c
@@ -12,6 +12,7 @@
#include "qemu/osdep.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
#include "qapi/qmp/qstring.h"
#include "qapi/qobject-input-visitor.h"
diff --git a/tests/test-netfilter.c b/tests/test-netfilter.c
index 2506473365..95f7839aef 100644
--- a/tests/test-netfilter.c
+++ b/tests/test-netfilter.c
@@ -10,6 +10,7 @@
#include "qemu/osdep.h"
#include "libqtest.h"
+#include "qapi/qmp/qdict.h"
/* add a netfilter to a netdev and then remove it */
static void add_one_netfilter(void)
diff --git a/tests/test-qemu-opts.c b/tests/test-qemu-opts.c
index cc1bb1afdf..b37d695c28 100644
--- a/tests/test-qemu-opts.c
+++ b/tests/test-qemu-opts.c
@@ -10,6 +10,7 @@
#include "qemu/osdep.h"
#include "qemu/cutils.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qstring.h"
#include "qemu/config-file.h"
diff --git a/tests/test-qga.c b/tests/test-qga.c
index e67c7289eb..5c5b661f8a 100644
--- a/tests/test-qga.c
+++ b/tests/test-qga.c
@@ -5,6 +5,7 @@
#include <sys/un.h>
#include "libqtest.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
typedef struct {
diff --git a/tests/test-qmp-event.c b/tests/test-qmp-event.c
index e5ee69e9af..8012341343 100644
--- a/tests/test-qmp-event.c
+++ b/tests/test-qmp-event.c
@@ -18,6 +18,7 @@
#include "test-qapi-event.h"
#include "qapi/error.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qnum.h"
#include "qapi/qmp/qstring.h"
#include "qapi/qmp-event.h"
diff --git a/tests/test-qobject-input-visitor.c b/tests/test-qobject-input-visitor.c
index 20bf9a5414..2e6f7f422f 100644
--- a/tests/test-qobject-input-visitor.c
+++ b/tests/test-qobject-input-visitor.c
@@ -18,6 +18,7 @@
#include "qapi/qobject-input-visitor.h"
#include "test-qapi-visit.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qnull.h"
#include "qapi/qmp/qnum.h"
#include "qapi/qmp/qjson.h"
diff --git a/tests/test-qobject-output-visitor.c b/tests/test-qobject-output-visitor.c
index 7cf86707ec..09a56d2d06 100644
--- a/tests/test-qobject-output-visitor.c
+++ b/tests/test-qobject-output-visitor.c
@@ -17,6 +17,7 @@
#include "qapi/qobject-output-visitor.h"
#include "test-qapi-visit.h"
#include "qapi/qmp/qbool.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
#include "qapi/qmp/qnull.h"
#include "qapi/qmp/qnum.h"
diff --git a/tests/test-replication.c b/tests/test-replication.c
index cebeb793b0..31372777ae 100644
--- a/tests/test-replication.c
+++ b/tests/test-replication.c
@@ -11,6 +11,7 @@
#include "qemu/osdep.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "replication.h"
#include "block/block_int.h"
#include "sysemu/block-backend.h"
diff --git a/tests/tmp105-test.c b/tests/tmp105-test.c
index a7940a4639..e9a3cb7ac3 100644
--- a/tests/tmp105-test.c
+++ b/tests/tmp105-test.c
@@ -11,6 +11,7 @@
#include "libqtest.h"
#include "libqos/i2c.h"
+#include "qapi/qmp/qdict.h"
#include "hw/misc/tmp105_regs.h"
#define OMAP2_I2C_1_BASE 0x48070000
diff --git a/tests/vhost-user-test.c b/tests/vhost-user-test.c
index 95eb449cfc..128fce302f 100644
--- a/tests/vhost-user-test.c
+++ b/tests/vhost-user-test.c
@@ -12,6 +12,7 @@
#include "libqtest.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qemu/config-file.h"
#include "qemu/option.h"
#include "qemu/range.h"
diff --git a/tests/virtio-net-test.c b/tests/virtio-net-test.c
index ea634dc05a..4114839457 100644
--- a/tests/virtio-net-test.c
+++ b/tests/virtio-net-test.c
@@ -16,6 +16,7 @@
#include "libqos/libqos-spapr.h"
#include "libqos/virtio.h"
#include "libqos/virtio-pci.h"
+#include "qapi/qmp/qdict.h"
#include "qemu/bswap.h"
#include "hw/virtio/virtio-net.h"
#include "standard-headers/linux/virtio_ids.h"
diff --git a/tests/vmgenid-test.c b/tests/vmgenid-test.c
index 68ff954578..7190e680dc 100644
--- a/tests/vmgenid-test.c
+++ b/tests/vmgenid-test.c
@@ -15,6 +15,7 @@
#include "boot-sector.h"
#include "acpi-utils.h"
#include "libqtest.h"
+#include "qapi/qmp/qdict.h"
#define VGID_GUID "324e6eaf-d1d1-4bf6-bf41-b9bb6c91fb87"
#define VMGENID_GUID_OFFSET 40 /* allow space for
diff --git a/tests/wdt_ib700-test.c b/tests/wdt_ib700-test.c
index 49f4f0c221..6062d4e942 100644
--- a/tests/wdt_ib700-test.c
+++ b/tests/wdt_ib700-test.c
@@ -9,6 +9,7 @@
#include "qemu/osdep.h"
#include "libqtest.h"
+#include "qapi/qmp/qdict.h"
#include "qemu/timer.h"
static void qmp_check_no_event(void)
diff --git a/ui/input.c b/ui/input.c
index a5f1cbb3ca..8bef0fb038 100644
--- a/ui/input.c
+++ b/ui/input.c
@@ -1,6 +1,7 @@
#include "qemu/osdep.h"
#include "sysemu/sysemu.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qemu/error-report.h"
#include "qmp-commands.h"
#include "trace.h"
diff --git a/util/keyval.c b/util/keyval.c
index 4085282a7a..212ae90d00 100644
--- a/util/keyval.c
+++ b/util/keyval.c
@@ -81,6 +81,7 @@
#include "qemu/osdep.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
#include "qapi/qmp/qstring.h"
#include "qemu/cutils.h"
diff --git a/util/qemu-config.c b/util/qemu-config.c
index 230c699a51..10cae120cc 100644
--- a/util/qemu-config.c
+++ b/util/qemu-config.c
@@ -1,5 +1,6 @@
#include "qemu/osdep.h"
#include "qapi/error.h"
+#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qlist.h"
#include "qemu-common.h"
#include "qemu/error-report.h"