aboutsummaryrefslogtreecommitdiff
path: root/include/hw/misc
diff options
context:
space:
mode:
Diffstat (limited to 'include/hw/misc')
-rw-r--r--include/hw/misc/a9scu.h4
-rw-r--r--include/hw/misc/allwinner-cpucfg.h4
-rw-r--r--include/hw/misc/allwinner-h3-ccu.h4
-rw-r--r--include/hw/misc/allwinner-h3-dramc.h4
-rw-r--r--include/hw/misc/allwinner-h3-sysctrl.h4
-rw-r--r--include/hw/misc/allwinner-sid.h4
-rw-r--r--include/hw/misc/arm11scu.h4
-rw-r--r--include/hw/misc/armsse-cpuid.h4
-rw-r--r--include/hw/misc/armsse-mhu.h4
-rw-r--r--include/hw/misc/aspeed_xdma.h4
-rw-r--r--include/hw/misc/auxbus.h11
-rw-r--r--include/hw/misc/avr_power.h4
-rw-r--r--include/hw/misc/bcm2835_mbox.h4
-rw-r--r--include/hw/misc/bcm2835_mphi.h3
-rw-r--r--include/hw/misc/bcm2835_property.h4
-rw-r--r--include/hw/misc/bcm2835_rng.h4
-rw-r--r--include/hw/misc/bcm2835_thermal.h4
-rw-r--r--include/hw/misc/grlib_ahb_apb_pnp.h8
-rw-r--r--include/hw/misc/imx25_ccm.h4
-rw-r--r--include/hw/misc/imx31_ccm.h4
-rw-r--r--include/hw/misc/imx6_ccm.h4
-rw-r--r--include/hw/misc/imx6_src.h4
-rw-r--r--include/hw/misc/imx6ul_ccm.h4
-rw-r--r--include/hw/misc/imx7_ccm.h8
-rw-r--r--include/hw/misc/imx7_gpr.h4
-rw-r--r--include/hw/misc/imx7_snvs.h4
-rw-r--r--include/hw/misc/imx_rngc.h4
-rw-r--r--include/hw/misc/iotkit-secctl.h4
-rw-r--r--include/hw/misc/iotkit-sysctl.h4
-rw-r--r--include/hw/misc/iotkit-sysinfo.h4
-rw-r--r--include/hw/misc/mac_via.h12
-rw-r--r--include/hw/misc/macio/cuda.h8
-rw-r--r--include/hw/misc/macio/gpio.h4
-rw-r--r--include/hw/misc/macio/macio.h20
-rw-r--r--include/hw/misc/macio/pmu.h8
-rw-r--r--include/hw/misc/max111x.h4
-rw-r--r--include/hw/misc/mips_cmgcr.h4
-rw-r--r--include/hw/misc/mips_cpc.h4
-rw-r--r--include/hw/misc/mips_itu.h4
-rw-r--r--include/hw/misc/mps2-fpgaio.h4
-rw-r--r--include/hw/misc/mps2-scc.h4
-rw-r--r--include/hw/misc/msf2-sysreg.h4
-rw-r--r--include/hw/misc/nrf51_rng.h4
-rw-r--r--include/hw/misc/stm32f2xx_syscfg.h4
-rw-r--r--include/hw/misc/stm32f4xx_exti.h4
-rw-r--r--include/hw/misc/stm32f4xx_syscfg.h4
-rw-r--r--include/hw/misc/tz-mpc.h4
-rw-r--r--include/hw/misc/tz-msc.h4
-rw-r--r--include/hw/misc/tz-ppc.h4
-rw-r--r--include/hw/misc/unimp.h4
-rw-r--r--include/hw/misc/zynq-xadc.h4
51 files changed, 63 insertions, 187 deletions
diff --git a/include/hw/misc/a9scu.h b/include/hw/misc/a9scu.h
index fd1b92e923..c3759fb8c8 100644
--- a/include/hw/misc/a9scu.h
+++ b/include/hw/misc/a9scu.h
@@ -25,10 +25,8 @@ struct A9SCUState {
uint32_t status;
uint32_t num_cpu;
};
-typedef struct A9SCUState A9SCUState;
#define TYPE_A9_SCU "a9-scu"
-DECLARE_INSTANCE_CHECKER(A9SCUState, A9_SCU,
- TYPE_A9_SCU)
+OBJECT_DECLARE_SIMPLE_TYPE(A9SCUState, A9_SCU)
#endif
diff --git a/include/hw/misc/allwinner-cpucfg.h b/include/hw/misc/allwinner-cpucfg.h
index 058514de15..a717b47299 100644
--- a/include/hw/misc/allwinner-cpucfg.h
+++ b/include/hw/misc/allwinner-cpucfg.h
@@ -29,9 +29,7 @@
*/
#define TYPE_AW_CPUCFG "allwinner-cpucfg"
-typedef struct AwCpuCfgState AwCpuCfgState;
-DECLARE_INSTANCE_CHECKER(AwCpuCfgState, AW_CPUCFG,
- TYPE_AW_CPUCFG)
+OBJECT_DECLARE_SIMPLE_TYPE(AwCpuCfgState, AW_CPUCFG)
/** @} */
diff --git a/include/hw/misc/allwinner-h3-ccu.h b/include/hw/misc/allwinner-h3-ccu.h
index 05f5c7bd8e..a04875bfca 100644
--- a/include/hw/misc/allwinner-h3-ccu.h
+++ b/include/hw/misc/allwinner-h3-ccu.h
@@ -42,9 +42,7 @@
*/
#define TYPE_AW_H3_CCU "allwinner-h3-ccu"
-typedef struct AwH3ClockCtlState AwH3ClockCtlState;
-DECLARE_INSTANCE_CHECKER(AwH3ClockCtlState, AW_H3_CCU,
- TYPE_AW_H3_CCU)
+OBJECT_DECLARE_SIMPLE_TYPE(AwH3ClockCtlState, AW_H3_CCU)
/** @} */
diff --git a/include/hw/misc/allwinner-h3-dramc.h b/include/hw/misc/allwinner-h3-dramc.h
index 60a13a6958..0b6c877ef7 100644
--- a/include/hw/misc/allwinner-h3-dramc.h
+++ b/include/hw/misc/allwinner-h3-dramc.h
@@ -58,9 +58,7 @@
*/
#define TYPE_AW_H3_DRAMC "allwinner-h3-dramc"
-typedef struct AwH3DramCtlState AwH3DramCtlState;
-DECLARE_INSTANCE_CHECKER(AwH3DramCtlState, AW_H3_DRAMC,
- TYPE_AW_H3_DRAMC)
+OBJECT_DECLARE_SIMPLE_TYPE(AwH3DramCtlState, AW_H3_DRAMC)
/** @} */
diff --git a/include/hw/misc/allwinner-h3-sysctrl.h b/include/hw/misc/allwinner-h3-sysctrl.h
index 50baa8eb07..ec1c220535 100644
--- a/include/hw/misc/allwinner-h3-sysctrl.h
+++ b/include/hw/misc/allwinner-h3-sysctrl.h
@@ -43,9 +43,7 @@
*/
#define TYPE_AW_H3_SYSCTRL "allwinner-h3-sysctrl"
-typedef struct AwH3SysCtrlState AwH3SysCtrlState;
-DECLARE_INSTANCE_CHECKER(AwH3SysCtrlState, AW_H3_SYSCTRL,
- TYPE_AW_H3_SYSCTRL)
+OBJECT_DECLARE_SIMPLE_TYPE(AwH3SysCtrlState, AW_H3_SYSCTRL)
/** @} */
diff --git a/include/hw/misc/allwinner-sid.h b/include/hw/misc/allwinner-sid.h
index b8e83bb7ce..3bfa887a96 100644
--- a/include/hw/misc/allwinner-sid.h
+++ b/include/hw/misc/allwinner-sid.h
@@ -30,9 +30,7 @@
*/
#define TYPE_AW_SID "allwinner-sid"
-typedef struct AwSidState AwSidState;
-DECLARE_INSTANCE_CHECKER(AwSidState, AW_SID,
- TYPE_AW_SID)
+OBJECT_DECLARE_SIMPLE_TYPE(AwSidState, AW_SID)
/** @} */
diff --git a/include/hw/misc/arm11scu.h b/include/hw/misc/arm11scu.h
index 71b4bc9a22..e5c0282aec 100644
--- a/include/hw/misc/arm11scu.h
+++ b/include/hw/misc/arm11scu.h
@@ -15,9 +15,7 @@
#include "qom/object.h"
#define TYPE_ARM11_SCU "arm11-scu"
-typedef struct ARM11SCUState ARM11SCUState;
-DECLARE_INSTANCE_CHECKER(ARM11SCUState, ARM11_SCU,
- TYPE_ARM11_SCU)
+OBJECT_DECLARE_SIMPLE_TYPE(ARM11SCUState, ARM11_SCU)
struct ARM11SCUState {
/*< private >*/
diff --git a/include/hw/misc/armsse-cpuid.h b/include/hw/misc/armsse-cpuid.h
index 80691c7180..a61355e516 100644
--- a/include/hw/misc/armsse-cpuid.h
+++ b/include/hw/misc/armsse-cpuid.h
@@ -26,9 +26,7 @@
#include "qom/object.h"
#define TYPE_ARMSSE_CPUID "armsse-cpuid"
-typedef struct ARMSSECPUID ARMSSECPUID;
-DECLARE_INSTANCE_CHECKER(ARMSSECPUID, ARMSSE_CPUID,
- TYPE_ARMSSE_CPUID)
+OBJECT_DECLARE_SIMPLE_TYPE(ARMSSECPUID, ARMSSE_CPUID)
struct ARMSSECPUID {
/*< private >*/
diff --git a/include/hw/misc/armsse-mhu.h b/include/hw/misc/armsse-mhu.h
index 310643a022..2671b5b978 100644
--- a/include/hw/misc/armsse-mhu.h
+++ b/include/hw/misc/armsse-mhu.h
@@ -27,9 +27,7 @@
#include "qom/object.h"
#define TYPE_ARMSSE_MHU "armsse-mhu"
-typedef struct ARMSSEMHU ARMSSEMHU;
-DECLARE_INSTANCE_CHECKER(ARMSSEMHU, ARMSSE_MHU,
- TYPE_ARMSSE_MHU)
+OBJECT_DECLARE_SIMPLE_TYPE(ARMSSEMHU, ARMSSE_MHU)
struct ARMSSEMHU {
/*< private >*/
diff --git a/include/hw/misc/aspeed_xdma.h b/include/hw/misc/aspeed_xdma.h
index 0e62c04520..9869ef4728 100644
--- a/include/hw/misc/aspeed_xdma.h
+++ b/include/hw/misc/aspeed_xdma.h
@@ -13,9 +13,7 @@
#include "qom/object.h"
#define TYPE_ASPEED_XDMA "aspeed.xdma"
-typedef struct AspeedXDMAState AspeedXDMAState;
-DECLARE_INSTANCE_CHECKER(AspeedXDMAState, ASPEED_XDMA,
- TYPE_ASPEED_XDMA)
+OBJECT_DECLARE_SIMPLE_TYPE(AspeedXDMAState, ASPEED_XDMA)
#define ASPEED_XDMA_NUM_REGS (ASPEED_XDMA_REG_SIZE / sizeof(uint32_t))
#define ASPEED_XDMA_REG_SIZE 0x7C
diff --git a/include/hw/misc/auxbus.h b/include/hw/misc/auxbus.h
index f910d94118..b05799d2f7 100644
--- a/include/hw/misc/auxbus.h
+++ b/include/hw/misc/auxbus.h
@@ -29,15 +29,12 @@
#include "hw/qdev-core.h"
#include "qom/object.h"
-typedef struct AUXBus AUXBus;
typedef struct AUXSlave AUXSlave;
typedef enum AUXCommand AUXCommand;
typedef enum AUXReply AUXReply;
#define TYPE_AUXTOI2C "aux-to-i2c-bridge"
-typedef struct AUXTOI2CState AUXTOI2CState;
-DECLARE_INSTANCE_CHECKER(AUXTOI2CState, AUXTOI2C,
- TYPE_AUXTOI2C)
+OBJECT_DECLARE_SIMPLE_TYPE(AUXTOI2CState, AUXTOI2C)
enum AUXCommand {
WRITE_I2C = 0,
@@ -58,8 +55,7 @@ enum AUXReply {
};
#define TYPE_AUX_BUS "aux-bus"
-DECLARE_INSTANCE_CHECKER(AUXBus, AUX_BUS,
- TYPE_AUX_BUS)
+OBJECT_DECLARE_SIMPLE_TYPE(AUXBus, AUX_BUS)
struct AUXBus {
/* < private > */
@@ -78,8 +74,7 @@ struct AUXBus {
};
#define TYPE_AUX_SLAVE "aux-slave"
-DECLARE_INSTANCE_CHECKER(AUXSlave, AUX_SLAVE,
- TYPE_AUX_SLAVE)
+OBJECT_DECLARE_SIMPLE_TYPE(AUXSlave, AUX_SLAVE)
struct AUXSlave {
/* < private > */
diff --git a/include/hw/misc/avr_power.h b/include/hw/misc/avr_power.h
index 938ab3e21b..707df030b1 100644
--- a/include/hw/misc/avr_power.h
+++ b/include/hw/misc/avr_power.h
@@ -31,9 +31,7 @@
#define TYPE_AVR_MASK "avr-power"
-typedef struct AVRMaskState AVRMaskState;
-DECLARE_INSTANCE_CHECKER(AVRMaskState, AVR_MASK,
- TYPE_AVR_MASK)
+OBJECT_DECLARE_SIMPLE_TYPE(AVRMaskState, AVR_MASK)
struct AVRMaskState {
/* <private> */
diff --git a/include/hw/misc/bcm2835_mbox.h b/include/hw/misc/bcm2835_mbox.h
index d8c8017f4e..ade27af25d 100644
--- a/include/hw/misc/bcm2835_mbox.h
+++ b/include/hw/misc/bcm2835_mbox.h
@@ -13,9 +13,7 @@
#include "qom/object.h"
#define TYPE_BCM2835_MBOX "bcm2835-mbox"
-typedef struct BCM2835MboxState BCM2835MboxState;
-DECLARE_INSTANCE_CHECKER(BCM2835MboxState, BCM2835_MBOX,
- TYPE_BCM2835_MBOX)
+OBJECT_DECLARE_SIMPLE_TYPE(BCM2835MboxState, BCM2835_MBOX)
typedef struct {
uint32_t reg[MBOX_SIZE];
diff --git a/include/hw/misc/bcm2835_mphi.h b/include/hw/misc/bcm2835_mphi.h
index 249511182e..751363f496 100644
--- a/include/hw/misc/bcm2835_mphi.h
+++ b/include/hw/misc/bcm2835_mphi.h
@@ -39,7 +39,6 @@ struct BCM2835MphiState {
#define TYPE_BCM2835_MPHI "bcm2835-mphi"
-DECLARE_INSTANCE_CHECKER(BCM2835MphiState, BCM2835_MPHI,
- TYPE_BCM2835_MPHI)
+OBJECT_DECLARE_SIMPLE_TYPE(BCM2835MphiState, BCM2835_MPHI)
#endif
diff --git a/include/hw/misc/bcm2835_property.h b/include/hw/misc/bcm2835_property.h
index 5c827a1900..712b76b7a3 100644
--- a/include/hw/misc/bcm2835_property.h
+++ b/include/hw/misc/bcm2835_property.h
@@ -14,9 +14,7 @@
#include "qom/object.h"
#define TYPE_BCM2835_PROPERTY "bcm2835-property"
-typedef struct BCM2835PropertyState BCM2835PropertyState;
-DECLARE_INSTANCE_CHECKER(BCM2835PropertyState, BCM2835_PROPERTY,
- TYPE_BCM2835_PROPERTY)
+OBJECT_DECLARE_SIMPLE_TYPE(BCM2835PropertyState, BCM2835_PROPERTY)
struct BCM2835PropertyState {
/*< private >*/
diff --git a/include/hw/misc/bcm2835_rng.h b/include/hw/misc/bcm2835_rng.h
index fec76eef8e..7c1fb3ef40 100644
--- a/include/hw/misc/bcm2835_rng.h
+++ b/include/hw/misc/bcm2835_rng.h
@@ -14,9 +14,7 @@
#include "qom/object.h"
#define TYPE_BCM2835_RNG "bcm2835-rng"
-typedef struct BCM2835RngState BCM2835RngState;
-DECLARE_INSTANCE_CHECKER(BCM2835RngState, BCM2835_RNG,
- TYPE_BCM2835_RNG)
+OBJECT_DECLARE_SIMPLE_TYPE(BCM2835RngState, BCM2835_RNG)
struct BCM2835RngState {
SysBusDevice busdev;
diff --git a/include/hw/misc/bcm2835_thermal.h b/include/hw/misc/bcm2835_thermal.h
index 5b827c970e..f90f9e487c 100644
--- a/include/hw/misc/bcm2835_thermal.h
+++ b/include/hw/misc/bcm2835_thermal.h
@@ -14,9 +14,7 @@
#define TYPE_BCM2835_THERMAL "bcm2835-thermal"
-typedef struct Bcm2835ThermalState Bcm2835ThermalState;
-DECLARE_INSTANCE_CHECKER(Bcm2835ThermalState, BCM2835_THERMAL,
- TYPE_BCM2835_THERMAL)
+OBJECT_DECLARE_SIMPLE_TYPE(Bcm2835ThermalState, BCM2835_THERMAL)
struct Bcm2835ThermalState {
/*< private >*/
diff --git a/include/hw/misc/grlib_ahb_apb_pnp.h b/include/hw/misc/grlib_ahb_apb_pnp.h
index 34b18e3193..341451bff6 100644
--- a/include/hw/misc/grlib_ahb_apb_pnp.h
+++ b/include/hw/misc/grlib_ahb_apb_pnp.h
@@ -26,14 +26,10 @@
#include "qom/object.h"
#define TYPE_GRLIB_AHB_PNP "grlib,ahbpnp"
-typedef struct AHBPnp AHBPnp;
-DECLARE_INSTANCE_CHECKER(AHBPnp, GRLIB_AHB_PNP,
- TYPE_GRLIB_AHB_PNP)
+OBJECT_DECLARE_SIMPLE_TYPE(AHBPnp, GRLIB_AHB_PNP)
#define TYPE_GRLIB_APB_PNP "grlib,apbpnp"
-typedef struct APBPnp APBPnp;
-DECLARE_INSTANCE_CHECKER(APBPnp, GRLIB_APB_PNP,
- TYPE_GRLIB_APB_PNP)
+OBJECT_DECLARE_SIMPLE_TYPE(APBPnp, GRLIB_APB_PNP)
void grlib_ahb_pnp_add_entry(AHBPnp *dev, uint32_t address, uint32_t mask,
uint8_t vendor, uint16_t device, int slave,
diff --git a/include/hw/misc/imx25_ccm.h b/include/hw/misc/imx25_ccm.h
index 55c5db8815..c3b89018c6 100644
--- a/include/hw/misc/imx25_ccm.h
+++ b/include/hw/misc/imx25_ccm.h
@@ -64,9 +64,7 @@
CCTL_##name##_SHIFT)
#define TYPE_IMX25_CCM "imx25.ccm"
-typedef struct IMX25CCMState IMX25CCMState;
-DECLARE_INSTANCE_CHECKER(IMX25CCMState, IMX25_CCM,
- TYPE_IMX25_CCM)
+OBJECT_DECLARE_SIMPLE_TYPE(IMX25CCMState, IMX25_CCM)
struct IMX25CCMState {
/* <private> */
diff --git a/include/hw/misc/imx31_ccm.h b/include/hw/misc/imx31_ccm.h
index 25e280e976..18e08ee84f 100644
--- a/include/hw/misc/imx31_ccm.h
+++ b/include/hw/misc/imx31_ccm.h
@@ -73,9 +73,7 @@
PDR0_##name##_PODF_SHIFT)
#define TYPE_IMX31_CCM "imx31.ccm"
-typedef struct IMX31CCMState IMX31CCMState;
-DECLARE_INSTANCE_CHECKER(IMX31CCMState, IMX31_CCM,
- TYPE_IMX31_CCM)
+OBJECT_DECLARE_SIMPLE_TYPE(IMX31CCMState, IMX31_CCM)
struct IMX31CCMState {
/* <private> */
diff --git a/include/hw/misc/imx6_ccm.h b/include/hw/misc/imx6_ccm.h
index 85f32417d6..ccf46d7353 100644
--- a/include/hw/misc/imx6_ccm.h
+++ b/include/hw/misc/imx6_ccm.h
@@ -179,9 +179,7 @@
#define EXTRACT(value, name) extract32(value, name##_SHIFT, name##_LENGTH)
#define TYPE_IMX6_CCM "imx6.ccm"
-typedef struct IMX6CCMState IMX6CCMState;
-DECLARE_INSTANCE_CHECKER(IMX6CCMState, IMX6_CCM,
- TYPE_IMX6_CCM)
+OBJECT_DECLARE_SIMPLE_TYPE(IMX6CCMState, IMX6_CCM)
struct IMX6CCMState {
/* <private> */
diff --git a/include/hw/misc/imx6_src.h b/include/hw/misc/imx6_src.h
index 15b51757ba..f380da3810 100644
--- a/include/hw/misc/imx6_src.h
+++ b/include/hw/misc/imx6_src.h
@@ -58,9 +58,7 @@
#define EXTRACT(value, name) extract32(value, name##_SHIFT, name##_LENGTH)
#define TYPE_IMX6_SRC "imx6.src"
-typedef struct IMX6SRCState IMX6SRCState;
-DECLARE_INSTANCE_CHECKER(IMX6SRCState, IMX6_SRC,
- TYPE_IMX6_SRC)
+OBJECT_DECLARE_SIMPLE_TYPE(IMX6SRCState, IMX6_SRC)
struct IMX6SRCState {
/* <private> */
diff --git a/include/hw/misc/imx6ul_ccm.h b/include/hw/misc/imx6ul_ccm.h
index d614de0edd..edb5f784d5 100644
--- a/include/hw/misc/imx6ul_ccm.h
+++ b/include/hw/misc/imx6ul_ccm.h
@@ -208,9 +208,7 @@
#define CCM_ANALOG_PLL_LOCK (1 << 31);
#define TYPE_IMX6UL_CCM "imx6ul.ccm"
-typedef struct IMX6ULCCMState IMX6ULCCMState;
-DECLARE_INSTANCE_CHECKER(IMX6ULCCMState, IMX6UL_CCM,
- TYPE_IMX6UL_CCM)
+OBJECT_DECLARE_SIMPLE_TYPE(IMX6ULCCMState, IMX6UL_CCM)
struct IMX6ULCCMState {
/* <private> */
diff --git a/include/hw/misc/imx7_ccm.h b/include/hw/misc/imx7_ccm.h
index e2757622d0..dcaebfb4ef 100644
--- a/include/hw/misc/imx7_ccm.h
+++ b/include/hw/misc/imx7_ccm.h
@@ -105,9 +105,7 @@ enum IMX7PMURegisters {
};
#define TYPE_IMX7_CCM "imx7.ccm"
-typedef struct IMX7CCMState IMX7CCMState;
-DECLARE_INSTANCE_CHECKER(IMX7CCMState, IMX7_CCM,
- TYPE_IMX7_CCM)
+OBJECT_DECLARE_SIMPLE_TYPE(IMX7CCMState, IMX7_CCM)
struct IMX7CCMState {
/* <private> */
@@ -121,9 +119,7 @@ struct IMX7CCMState {
#define TYPE_IMX7_ANALOG "imx7.analog"
-typedef struct IMX7AnalogState IMX7AnalogState;
-DECLARE_INSTANCE_CHECKER(IMX7AnalogState, IMX7_ANALOG,
- TYPE_IMX7_ANALOG)
+OBJECT_DECLARE_SIMPLE_TYPE(IMX7AnalogState, IMX7_ANALOG)
struct IMX7AnalogState {
/* <private> */
diff --git a/include/hw/misc/imx7_gpr.h b/include/hw/misc/imx7_gpr.h
index f80b3ed28c..df364bd8f0 100644
--- a/include/hw/misc/imx7_gpr.h
+++ b/include/hw/misc/imx7_gpr.h
@@ -17,9 +17,7 @@
#include "qom/object.h"
#define TYPE_IMX7_GPR "imx7.gpr"
-typedef struct IMX7GPRState IMX7GPRState;
-DECLARE_INSTANCE_CHECKER(IMX7GPRState, IMX7_GPR,
- TYPE_IMX7_GPR)
+OBJECT_DECLARE_SIMPLE_TYPE(IMX7GPRState, IMX7_GPR)
struct IMX7GPRState {
/* <private> */
diff --git a/include/hw/misc/imx7_snvs.h b/include/hw/misc/imx7_snvs.h
index ea5395c107..14a1d6fe6b 100644
--- a/include/hw/misc/imx7_snvs.h
+++ b/include/hw/misc/imx7_snvs.h
@@ -24,9 +24,7 @@ enum IMX7SNVSRegisters {
};
#define TYPE_IMX7_SNVS "imx7.snvs"
-typedef struct IMX7SNVSState IMX7SNVSState;
-DECLARE_INSTANCE_CHECKER(IMX7SNVSState, IMX7_SNVS,
- TYPE_IMX7_SNVS)
+OBJECT_DECLARE_SIMPLE_TYPE(IMX7SNVSState, IMX7_SNVS)
struct IMX7SNVSState {
/* <private> */
diff --git a/include/hw/misc/imx_rngc.h b/include/hw/misc/imx_rngc.h
index f7b569cac5..34ad699225 100644
--- a/include/hw/misc/imx_rngc.h
+++ b/include/hw/misc/imx_rngc.h
@@ -14,9 +14,7 @@
#include "qom/object.h"
#define TYPE_IMX_RNGC "imx.rngc"
-typedef struct IMXRNGCState IMXRNGCState;
-DECLARE_INSTANCE_CHECKER(IMXRNGCState, IMX_RNGC,
- TYPE_IMX_RNGC)
+OBJECT_DECLARE_SIMPLE_TYPE(IMXRNGCState, IMX_RNGC)
struct IMXRNGCState {
/*< private >*/
diff --git a/include/hw/misc/iotkit-secctl.h b/include/hw/misc/iotkit-secctl.h
index d062ed43e7..54c212b515 100644
--- a/include/hw/misc/iotkit-secctl.h
+++ b/include/hw/misc/iotkit-secctl.h
@@ -59,9 +59,7 @@
#include "qom/object.h"
#define TYPE_IOTKIT_SECCTL "iotkit-secctl"
-typedef struct IoTKitSecCtl IoTKitSecCtl;
-DECLARE_INSTANCE_CHECKER(IoTKitSecCtl, IOTKIT_SECCTL,
- TYPE_IOTKIT_SECCTL)
+OBJECT_DECLARE_SIMPLE_TYPE(IoTKitSecCtl, IOTKIT_SECCTL)
#define IOTS_APB_PPC0_NUM_PORTS 3
#define IOTS_APB_PPC1_NUM_PORTS 1
diff --git a/include/hw/misc/iotkit-sysctl.h b/include/hw/misc/iotkit-sysctl.h
index 22ceb5d76d..2b5636b218 100644
--- a/include/hw/misc/iotkit-sysctl.h
+++ b/include/hw/misc/iotkit-sysctl.h
@@ -31,9 +31,7 @@
#include "qom/object.h"
#define TYPE_IOTKIT_SYSCTL "iotkit-sysctl"
-typedef struct IoTKitSysCtl IoTKitSysCtl;
-DECLARE_INSTANCE_CHECKER(IoTKitSysCtl, IOTKIT_SYSCTL,
- TYPE_IOTKIT_SYSCTL)
+OBJECT_DECLARE_SIMPLE_TYPE(IoTKitSysCtl, IOTKIT_SYSCTL)
struct IoTKitSysCtl {
/*< private >*/
diff --git a/include/hw/misc/iotkit-sysinfo.h b/include/hw/misc/iotkit-sysinfo.h
index 23ae43e549..7e620e2eaf 100644
--- a/include/hw/misc/iotkit-sysinfo.h
+++ b/include/hw/misc/iotkit-sysinfo.h
@@ -26,9 +26,7 @@
#include "qom/object.h"
#define TYPE_IOTKIT_SYSINFO "iotkit-sysinfo"
-typedef struct IoTKitSysInfo IoTKitSysInfo;
-DECLARE_INSTANCE_CHECKER(IoTKitSysInfo, IOTKIT_SYSINFO,
- TYPE_IOTKIT_SYSINFO)
+OBJECT_DECLARE_SIMPLE_TYPE(IoTKitSysInfo, IOTKIT_SYSINFO)
struct IoTKitSysInfo {
/*< private >*/
diff --git a/include/hw/misc/mac_via.h b/include/hw/misc/mac_via.h
index 862cbba3ab..a59f0bd422 100644
--- a/include/hw/misc/mac_via.h
+++ b/include/hw/misc/mac_via.h
@@ -32,9 +32,7 @@
#define TYPE_MOS6522_Q800_VIA1 "mos6522-q800-via1"
-typedef struct MOS6522Q800VIA1State MOS6522Q800VIA1State;
-DECLARE_INSTANCE_CHECKER(MOS6522Q800VIA1State, MOS6522_Q800_VIA1,
- TYPE_MOS6522_Q800_VIA1)
+OBJECT_DECLARE_SIMPLE_TYPE(MOS6522Q800VIA1State, MOS6522_Q800_VIA1)
struct MOS6522Q800VIA1State {
/*< private >*/
@@ -68,9 +66,7 @@ struct MOS6522Q800VIA1State {
#define VIA2_IRQ_ASC (1 << VIA2_IRQ_ASC_BIT)
#define TYPE_MOS6522_Q800_VIA2 "mos6522-q800-via2"
-typedef struct MOS6522Q800VIA2State MOS6522Q800VIA2State;
-DECLARE_INSTANCE_CHECKER(MOS6522Q800VIA2State, MOS6522_Q800_VIA2,
- TYPE_MOS6522_Q800_VIA2)
+OBJECT_DECLARE_SIMPLE_TYPE(MOS6522Q800VIA2State, MOS6522_Q800_VIA2)
struct MOS6522Q800VIA2State {
/*< private >*/
@@ -79,9 +75,7 @@ struct MOS6522Q800VIA2State {
#define TYPE_MAC_VIA "mac_via"
-typedef struct MacVIAState MacVIAState;
-DECLARE_INSTANCE_CHECKER(MacVIAState, MAC_VIA,
- TYPE_MAC_VIA)
+OBJECT_DECLARE_SIMPLE_TYPE(MacVIAState, MAC_VIA)
struct MacVIAState {
SysBusDevice busdev;
diff --git a/include/hw/misc/macio/cuda.h b/include/hw/misc/macio/cuda.h
index e738b6376f..a71deec968 100644
--- a/include/hw/misc/macio/cuda.h
+++ b/include/hw/misc/macio/cuda.h
@@ -63,17 +63,13 @@ struct MOS6522CUDAState {
/*< private >*/
MOS6522State parent_obj;
};
-typedef struct MOS6522CUDAState MOS6522CUDAState;
#define TYPE_MOS6522_CUDA "mos6522-cuda"
-DECLARE_INSTANCE_CHECKER(MOS6522CUDAState, MOS6522_CUDA,
- TYPE_MOS6522_CUDA)
+OBJECT_DECLARE_SIMPLE_TYPE(MOS6522CUDAState, MOS6522_CUDA)
/* Cuda */
#define TYPE_CUDA "cuda"
-typedef struct CUDAState CUDAState;
-DECLARE_INSTANCE_CHECKER(CUDAState, CUDA,
- TYPE_CUDA)
+OBJECT_DECLARE_SIMPLE_TYPE(CUDAState, CUDA)
struct CUDAState {
/*< private >*/
diff --git a/include/hw/misc/macio/gpio.h b/include/hw/misc/macio/gpio.h
index 1d0c8434ae..4dee09a9dd 100644
--- a/include/hw/misc/macio/gpio.h
+++ b/include/hw/misc/macio/gpio.h
@@ -31,9 +31,7 @@
#include "qom/object.h"
#define TYPE_MACIO_GPIO "macio-gpio"
-typedef struct MacIOGPIOState MacIOGPIOState;
-DECLARE_INSTANCE_CHECKER(MacIOGPIOState, MACIO_GPIO,
- TYPE_MACIO_GPIO)
+OBJECT_DECLARE_SIMPLE_TYPE(MacIOGPIOState, MACIO_GPIO)
struct MacIOGPIOState {
/*< private >*/
diff --git a/include/hw/misc/macio/macio.h b/include/hw/misc/macio/macio.h
index 02dbf37630..22b4e64b2c 100644
--- a/include/hw/misc/macio/macio.h
+++ b/include/hw/misc/macio/macio.h
@@ -40,9 +40,7 @@
/* MacIO virtual bus */
#define TYPE_MACIO_BUS "macio-bus"
-typedef struct MacIOBusState MacIOBusState;
-DECLARE_INSTANCE_CHECKER(MacIOBusState, MACIO_BUS,
- TYPE_MACIO_BUS)
+OBJECT_DECLARE_SIMPLE_TYPE(MacIOBusState, MACIO_BUS)
struct MacIOBusState {
/*< private >*/
@@ -51,9 +49,7 @@ struct MacIOBusState {
/* MacIO IDE */
#define TYPE_MACIO_IDE "macio-ide"
-typedef struct MACIOIDEState MACIOIDEState;
-DECLARE_INSTANCE_CHECKER(MACIOIDEState, MACIO_IDE,
- TYPE_MACIO_IDE)
+OBJECT_DECLARE_SIMPLE_TYPE(MACIOIDEState, MACIO_IDE)
struct MACIOIDEState {
/*< private >*/
@@ -79,9 +75,7 @@ void macio_ide_init_drives(MACIOIDEState *ide, DriveInfo **hd_table);
void macio_ide_register_dma(MACIOIDEState *ide);
#define TYPE_MACIO "macio"
-typedef struct MacIOState MacIOState;
-DECLARE_INSTANCE_CHECKER(MacIOState, MACIO,
- TYPE_MACIO)
+OBJECT_DECLARE_SIMPLE_TYPE(MacIOState, MACIO)
struct MacIOState {
/*< private >*/
@@ -98,9 +92,7 @@ struct MacIOState {
};
#define TYPE_OLDWORLD_MACIO "macio-oldworld"
-typedef struct OldWorldMacIOState OldWorldMacIOState;
-DECLARE_INSTANCE_CHECKER(OldWorldMacIOState, OLDWORLD_MACIO,
- TYPE_OLDWORLD_MACIO)
+OBJECT_DECLARE_SIMPLE_TYPE(OldWorldMacIOState, OLDWORLD_MACIO)
struct OldWorldMacIOState {
/*< private >*/
@@ -114,9 +106,7 @@ struct OldWorldMacIOState {
};
#define TYPE_NEWWORLD_MACIO "macio-newworld"
-typedef struct NewWorldMacIOState NewWorldMacIOState;
-DECLARE_INSTANCE_CHECKER(NewWorldMacIOState, NEWWORLD_MACIO,
- TYPE_NEWWORLD_MACIO)
+OBJECT_DECLARE_SIMPLE_TYPE(NewWorldMacIOState, NEWWORLD_MACIO)
struct NewWorldMacIOState {
/*< private >*/
diff --git a/include/hw/misc/macio/pmu.h b/include/hw/misc/macio/pmu.h
index 0d1a5c1406..78237d99a2 100644
--- a/include/hw/misc/macio/pmu.h
+++ b/include/hw/misc/macio/pmu.h
@@ -178,11 +178,9 @@ struct MOS6522PMUState {
/*< private >*/
MOS6522State parent_obj;
};
-typedef struct MOS6522PMUState MOS6522PMUState;
#define TYPE_MOS6522_PMU "mos6522-pmu"
-DECLARE_INSTANCE_CHECKER(MOS6522PMUState, MOS6522_PMU,
- TYPE_MOS6522_PMU)
+OBJECT_DECLARE_SIMPLE_TYPE(MOS6522PMUState, MOS6522_PMU)
/**
* PMUState:
* @last_b: last value of B register
@@ -231,10 +229,8 @@ struct PMUState {
/* GPIO */
MacIOGPIOState *gpio;
};
-typedef struct PMUState PMUState;
#define TYPE_VIA_PMU "via-pmu"
-DECLARE_INSTANCE_CHECKER(PMUState, VIA_PMU,
- TYPE_VIA_PMU)
+OBJECT_DECLARE_SIMPLE_TYPE(PMUState, VIA_PMU)
#endif /* PMU_H */
diff --git a/include/hw/misc/max111x.h b/include/hw/misc/max111x.h
index 6350a3f7c0..606cf1e0a2 100644
--- a/include/hw/misc/max111x.h
+++ b/include/hw/misc/max111x.h
@@ -45,12 +45,10 @@ struct MAX111xState {
uint8_t input[8];
int inputs, com;
};
-typedef struct MAX111xState MAX111xState;
#define TYPE_MAX_111X "max111x"
-DECLARE_INSTANCE_CHECKER(MAX111xState, MAX_111X,
- TYPE_MAX_111X)
+OBJECT_DECLARE_SIMPLE_TYPE(MAX111xState, MAX_111X)
#define TYPE_MAX_1110 "max1110"
#define TYPE_MAX_1111 "max1111"
diff --git a/include/hw/misc/mips_cmgcr.h b/include/hw/misc/mips_cmgcr.h
index 923df4f112..9fa58942d7 100644
--- a/include/hw/misc/mips_cmgcr.h
+++ b/include/hw/misc/mips_cmgcr.h
@@ -14,9 +14,7 @@
#include "qom/object.h"
#define TYPE_MIPS_GCR "mips-gcr"
-typedef struct MIPSGCRState MIPSGCRState;
-DECLARE_INSTANCE_CHECKER(MIPSGCRState, MIPS_GCR,
- TYPE_MIPS_GCR)
+OBJECT_DECLARE_SIMPLE_TYPE(MIPSGCRState, MIPS_GCR)
#define GCR_BASE_ADDR 0x1fbf8000ULL
#define GCR_ADDRSPACE_SZ 0x8000
diff --git a/include/hw/misc/mips_cpc.h b/include/hw/misc/mips_cpc.h
index 7dc188e8a2..e5dccea151 100644
--- a/include/hw/misc/mips_cpc.h
+++ b/include/hw/misc/mips_cpc.h
@@ -35,9 +35,7 @@
#define CPC_VP_RUNNING_OFS 0x30
#define TYPE_MIPS_CPC "mips-cpc"
-typedef struct MIPSCPCState MIPSCPCState;
-DECLARE_INSTANCE_CHECKER(MIPSCPCState, MIPS_CPC,
- TYPE_MIPS_CPC)
+OBJECT_DECLARE_SIMPLE_TYPE(MIPSCPCState, MIPS_CPC)
struct MIPSCPCState {
SysBusDevice parent_obj;
diff --git a/include/hw/misc/mips_itu.h b/include/hw/misc/mips_itu.h
index 7c19f61fbb..96347dbf65 100644
--- a/include/hw/misc/mips_itu.h
+++ b/include/hw/misc/mips_itu.h
@@ -24,9 +24,7 @@
#include "qom/object.h"
#define TYPE_MIPS_ITU "mips-itu"
-typedef struct MIPSITUState MIPSITUState;
-DECLARE_INSTANCE_CHECKER(MIPSITUState, MIPS_ITU,
- TYPE_MIPS_ITU)
+OBJECT_DECLARE_SIMPLE_TYPE(MIPSITUState, MIPS_ITU)
#define ITC_CELL_DEPTH_SHIFT 2
#define ITC_CELL_DEPTH (1u << ITC_CELL_DEPTH_SHIFT)
diff --git a/include/hw/misc/mps2-fpgaio.h b/include/hw/misc/mps2-fpgaio.h
index 991f5b731e..80f9227aa6 100644
--- a/include/hw/misc/mps2-fpgaio.h
+++ b/include/hw/misc/mps2-fpgaio.h
@@ -25,9 +25,7 @@
#include "qom/object.h"
#define TYPE_MPS2_FPGAIO "mps2-fpgaio"
-typedef struct MPS2FPGAIO MPS2FPGAIO;
-DECLARE_INSTANCE_CHECKER(MPS2FPGAIO, MPS2_FPGAIO,
- TYPE_MPS2_FPGAIO)
+OBJECT_DECLARE_SIMPLE_TYPE(MPS2FPGAIO, MPS2_FPGAIO)
struct MPS2FPGAIO {
/*< private >*/
diff --git a/include/hw/misc/mps2-scc.h b/include/hw/misc/mps2-scc.h
index 445e268b1f..e922b3c8e0 100644
--- a/include/hw/misc/mps2-scc.h
+++ b/include/hw/misc/mps2-scc.h
@@ -16,9 +16,7 @@
#include "qom/object.h"
#define TYPE_MPS2_SCC "mps2-scc"
-typedef struct MPS2SCC MPS2SCC;
-DECLARE_INSTANCE_CHECKER(MPS2SCC, MPS2_SCC,
- TYPE_MPS2_SCC)
+OBJECT_DECLARE_SIMPLE_TYPE(MPS2SCC, MPS2_SCC)
#define NUM_OSCCLK 3
diff --git a/include/hw/misc/msf2-sysreg.h b/include/hw/misc/msf2-sysreg.h
index 625932354a..fc1890e710 100644
--- a/include/hw/misc/msf2-sysreg.h
+++ b/include/hw/misc/msf2-sysreg.h
@@ -62,9 +62,7 @@ enum {
#define MSF2_SYSREG_MMIO_SIZE 0x300
#define TYPE_MSF2_SYSREG "msf2-sysreg"
-typedef struct MSF2SysregState MSF2SysregState;
-DECLARE_INSTANCE_CHECKER(MSF2SysregState, MSF2_SYSREG,
- TYPE_MSF2_SYSREG)
+OBJECT_DECLARE_SIMPLE_TYPE(MSF2SysregState, MSF2_SYSREG)
struct MSF2SysregState {
SysBusDevice parent_obj;
diff --git a/include/hw/misc/nrf51_rng.h b/include/hw/misc/nrf51_rng.h
index 7f2263a906..9aff9a76f8 100644
--- a/include/hw/misc/nrf51_rng.h
+++ b/include/hw/misc/nrf51_rng.h
@@ -38,9 +38,7 @@
#include "qemu/timer.h"
#include "qom/object.h"
#define TYPE_NRF51_RNG "nrf51_soc.rng"
-typedef struct NRF51RNGState NRF51RNGState;
-DECLARE_INSTANCE_CHECKER(NRF51RNGState, NRF51_RNG,
- TYPE_NRF51_RNG)
+OBJECT_DECLARE_SIMPLE_TYPE(NRF51RNGState, NRF51_RNG)
#define NRF51_RNG_SIZE 0x1000
diff --git a/include/hw/misc/stm32f2xx_syscfg.h b/include/hw/misc/stm32f2xx_syscfg.h
index 82ccd7cc24..57a98c533d 100644
--- a/include/hw/misc/stm32f2xx_syscfg.h
+++ b/include/hw/misc/stm32f2xx_syscfg.h
@@ -37,9 +37,7 @@
#define SYSCFG_CMPCR 0x20
#define TYPE_STM32F2XX_SYSCFG "stm32f2xx-syscfg"
-typedef struct STM32F2XXSyscfgState STM32F2XXSyscfgState;
-DECLARE_INSTANCE_CHECKER(STM32F2XXSyscfgState, STM32F2XX_SYSCFG,
- TYPE_STM32F2XX_SYSCFG)
+OBJECT_DECLARE_SIMPLE_TYPE(STM32F2XXSyscfgState, STM32F2XX_SYSCFG)
struct STM32F2XXSyscfgState {
/* <private> */
diff --git a/include/hw/misc/stm32f4xx_exti.h b/include/hw/misc/stm32f4xx_exti.h
index 4987c286ed..24b6fa7724 100644
--- a/include/hw/misc/stm32f4xx_exti.h
+++ b/include/hw/misc/stm32f4xx_exti.h
@@ -37,9 +37,7 @@
#define EXTI_PR 0x14
#define TYPE_STM32F4XX_EXTI "stm32f4xx-exti"
-typedef struct STM32F4xxExtiState STM32F4xxExtiState;
-DECLARE_INSTANCE_CHECKER(STM32F4xxExtiState, STM32F4XX_EXTI,
- TYPE_STM32F4XX_EXTI)
+OBJECT_DECLARE_SIMPLE_TYPE(STM32F4xxExtiState, STM32F4XX_EXTI)
#define NUM_GPIO_EVENT_IN_LINES 16
#define NUM_INTERRUPT_OUT_LINES 16
diff --git a/include/hw/misc/stm32f4xx_syscfg.h b/include/hw/misc/stm32f4xx_syscfg.h
index c3d89d4536..8c31feccd3 100644
--- a/include/hw/misc/stm32f4xx_syscfg.h
+++ b/include/hw/misc/stm32f4xx_syscfg.h
@@ -38,9 +38,7 @@
#define SYSCFG_CMPCR 0x20
#define TYPE_STM32F4XX_SYSCFG "stm32f4xx-syscfg"
-typedef struct STM32F4xxSyscfgState STM32F4xxSyscfgState;
-DECLARE_INSTANCE_CHECKER(STM32F4xxSyscfgState, STM32F4XX_SYSCFG,
- TYPE_STM32F4XX_SYSCFG)
+OBJECT_DECLARE_SIMPLE_TYPE(STM32F4xxSyscfgState, STM32F4XX_SYSCFG)
#define SYSCFG_NUM_EXTICR 4
diff --git a/include/hw/misc/tz-mpc.h b/include/hw/misc/tz-mpc.h
index 34e45fdb97..74d5d822cf 100644
--- a/include/hw/misc/tz-mpc.h
+++ b/include/hw/misc/tz-mpc.h
@@ -35,9 +35,7 @@
#include "qom/object.h"
#define TYPE_TZ_MPC "tz-mpc"
-typedef struct TZMPC TZMPC;
-DECLARE_INSTANCE_CHECKER(TZMPC, TZ_MPC,
- TYPE_TZ_MPC)
+OBJECT_DECLARE_SIMPLE_TYPE(TZMPC, TZ_MPC)
#define TZ_NUM_PORTS 16
diff --git a/include/hw/misc/tz-msc.h b/include/hw/misc/tz-msc.h
index 7169f330ff..77cc7f2404 100644
--- a/include/hw/misc/tz-msc.h
+++ b/include/hw/misc/tz-msc.h
@@ -55,9 +55,7 @@
#include "qom/object.h"
#define TYPE_TZ_MSC "tz-msc"
-typedef struct TZMSC TZMSC;
-DECLARE_INSTANCE_CHECKER(TZMSC, TZ_MSC,
- TYPE_TZ_MSC)
+OBJECT_DECLARE_SIMPLE_TYPE(TZMSC, TZ_MSC)
struct TZMSC {
/*< private >*/
diff --git a/include/hw/misc/tz-ppc.h b/include/hw/misc/tz-ppc.h
index b5251b715e..021d671b29 100644
--- a/include/hw/misc/tz-ppc.h
+++ b/include/hw/misc/tz-ppc.h
@@ -69,9 +69,7 @@
#include "qom/object.h"
#define TYPE_TZ_PPC "tz-ppc"
-typedef struct TZPPC TZPPC;
-DECLARE_INSTANCE_CHECKER(TZPPC, TZ_PPC,
- TYPE_TZ_PPC)
+OBJECT_DECLARE_SIMPLE_TYPE(TZPPC, TZ_PPC)
#define TZ_NUM_PORTS 16
diff --git a/include/hw/misc/unimp.h b/include/hw/misc/unimp.h
index 7c724bab94..518d627dc5 100644
--- a/include/hw/misc/unimp.h
+++ b/include/hw/misc/unimp.h
@@ -15,9 +15,7 @@
#define TYPE_UNIMPLEMENTED_DEVICE "unimplemented-device"
-typedef struct UnimplementedDeviceState UnimplementedDeviceState;
-DECLARE_INSTANCE_CHECKER(UnimplementedDeviceState, UNIMPLEMENTED_DEVICE,
- TYPE_UNIMPLEMENTED_DEVICE)
+OBJECT_DECLARE_SIMPLE_TYPE(UnimplementedDeviceState, UNIMPLEMENTED_DEVICE)
struct UnimplementedDeviceState {
SysBusDevice parent_obj;
diff --git a/include/hw/misc/zynq-xadc.h b/include/hw/misc/zynq-xadc.h
index 052f47954f..602bfb4ab1 100644
--- a/include/hw/misc/zynq-xadc.h
+++ b/include/hw/misc/zynq-xadc.h
@@ -24,9 +24,7 @@
#define ZYNQ_XADC_FIFO_DEPTH 15
#define TYPE_ZYNQ_XADC "xlnx,zynq-xadc"
-typedef struct ZynqXADCState ZynqXADCState;
-DECLARE_INSTANCE_CHECKER(ZynqXADCState, ZYNQ_XADC,
- TYPE_ZYNQ_XADC)
+OBJECT_DECLARE_SIMPLE_TYPE(ZynqXADCState, ZYNQ_XADC)
struct ZynqXADCState {
/*< private >*/