From a27bd6c779badb8d76e4430d810ef710a1b98f4e Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Mon, 12 Aug 2019 07:23:51 +0200 Subject: Include hw/qdev-properties.h less MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In my "build everything" tree, changing hw/qdev-properties.h triggers a recompile of some 2700 out of 6600 objects (not counting tests and objects that don't depend on qemu/osdep.h). Many places including hw/qdev-properties.h (directly or via hw/qdev.h) actually need only hw/qdev-core.h. Include hw/qdev-core.h there instead. hw/qdev.h is actually pointless: all it does is include hw/qdev-core.h and hw/qdev-properties.h, which in turn includes hw/qdev-core.h. Replace the remaining uses of hw/qdev.h by hw/qdev-properties.h. While there, delete a few superfluous inclusions of hw/qdev-core.h. Touching hw/qdev-properties.h now recompiles some 1200 objects. Cc: Paolo Bonzini Cc: "Daniel P. Berrangé" Cc: Eduardo Habkost Signed-off-by: Markus Armbruster Reviewed-by: Eduardo Habkost Message-Id: <20190812052359.30071-22-armbru@redhat.com> --- hw/nvram/ds1225y.c | 1 + hw/nvram/eeprom_at24c.c | 1 + hw/nvram/fw_cfg.c | 1 + hw/nvram/mac_nvram.c | 1 + hw/nvram/nrf51_nvm.c | 1 + hw/nvram/spapr_nvram.c | 1 + 6 files changed, 6 insertions(+) (limited to 'hw/nvram') diff --git a/hw/nvram/ds1225y.c b/hw/nvram/ds1225y.c index 9cddb37..934e09b 100644 --- a/hw/nvram/ds1225y.c +++ b/hw/nvram/ds1225y.c @@ -23,6 +23,7 @@ */ #include "qemu/osdep.h" +#include "hw/qdev-properties.h" #include "hw/sysbus.h" #include "migration/vmstate.h" #include "trace.h" diff --git a/hw/nvram/eeprom_at24c.c b/hw/nvram/eeprom_at24c.c index 00f942d..3416367 100644 --- a/hw/nvram/eeprom_at24c.c +++ b/hw/nvram/eeprom_at24c.c @@ -12,6 +12,7 @@ #include "qapi/error.h" #include "qemu/module.h" #include "hw/i2c/i2c.h" +#include "hw/qdev-properties.h" #include "sysemu/block-backend.h" /* #define DEBUG_AT24C */ diff --git a/hw/nvram/fw_cfg.c b/hw/nvram/fw_cfg.c index f192c3e..7dc3ac3 100644 --- a/hw/nvram/fw_cfg.c +++ b/hw/nvram/fw_cfg.c @@ -29,6 +29,7 @@ #include "sysemu/reset.h" #include "hw/boards.h" #include "hw/nvram/fw_cfg.h" +#include "hw/qdev-properties.h" #include "hw/sysbus.h" #include "migration/qemu-file-types.h" #include "migration/vmstate.h" diff --git a/hw/nvram/mac_nvram.c b/hw/nvram/mac_nvram.c index 853b693..9a47e35 100644 --- a/hw/nvram/mac_nvram.c +++ b/hw/nvram/mac_nvram.c @@ -26,6 +26,7 @@ #include "qemu/osdep.h" #include "hw/nvram/chrp_nvram.h" #include "hw/ppc/mac.h" +#include "hw/qdev-properties.h" #include "migration/vmstate.h" #include "qemu/cutils.h" #include "qemu/module.h" diff --git a/hw/nvram/nrf51_nvm.c b/hw/nvram/nrf51_nvm.c index e13ff4b..4d678f9 100644 --- a/hw/nvram/nrf51_nvm.c +++ b/hw/nvram/nrf51_nvm.c @@ -24,6 +24,7 @@ #include "exec/address-spaces.h" #include "hw/arm/nrf51.h" #include "hw/nvram/nrf51_nvm.h" +#include "hw/qdev-properties.h" #include "migration/vmstate.h" /* diff --git a/hw/nvram/spapr_nvram.c b/hw/nvram/spapr_nvram.c index ef22962..c7bcd29 100644 --- a/hw/nvram/spapr_nvram.c +++ b/hw/nvram/spapr_nvram.c @@ -36,6 +36,7 @@ #include "hw/nvram/chrp_nvram.h" #include "hw/ppc/spapr.h" #include "hw/ppc/spapr_vio.h" +#include "hw/qdev-properties.h" typedef struct SpaprNvram { SpaprVioDevice sdev; -- cgit v1.1