aboutsummaryrefslogtreecommitdiff
path: root/hw/i2c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/i2c')
-rw-r--r--hw/i2c/bitbang_i2c.c4
-rw-r--r--hw/i2c/exynos4210_i2c.c4
-rw-r--r--hw/i2c/mpc_i2c.c4
-rw-r--r--hw/i2c/smbus_eeprom.c4
-rw-r--r--hw/i2c/smbus_ich9.c4
5 files changed, 5 insertions, 15 deletions
diff --git a/hw/i2c/bitbang_i2c.c b/hw/i2c/bitbang_i2c.c
index c1b9f298d9..e9a0612a04 100644
--- a/hw/i2c/bitbang_i2c.c
+++ b/hw/i2c/bitbang_i2c.c
@@ -163,9 +163,7 @@ void bitbang_i2c_init(bitbang_i2c_interface *s, I2CBus *bus)
/* GPIO interface. */
#define TYPE_GPIO_I2C "gpio_i2c"
-typedef struct GPIOI2CState GPIOI2CState;
-DECLARE_INSTANCE_CHECKER(GPIOI2CState, GPIO_I2C,
- TYPE_GPIO_I2C)
+OBJECT_DECLARE_SIMPLE_TYPE(GPIOI2CState, GPIO_I2C)
struct GPIOI2CState {
SysBusDevice parent_obj;
diff --git a/hw/i2c/exynos4210_i2c.c b/hw/i2c/exynos4210_i2c.c
index ff82226e9f..b65a7d0222 100644
--- a/hw/i2c/exynos4210_i2c.c
+++ b/hw/i2c/exynos4210_i2c.c
@@ -34,9 +34,7 @@
#endif
#define TYPE_EXYNOS4_I2C "exynos4210.i2c"
-typedef struct Exynos4210I2CState Exynos4210I2CState;
-DECLARE_INSTANCE_CHECKER(Exynos4210I2CState, EXYNOS4_I2C,
- TYPE_EXYNOS4_I2C)
+OBJECT_DECLARE_SIMPLE_TYPE(Exynos4210I2CState, EXYNOS4_I2C)
/* Exynos4210 I2C memory map */
#define EXYNOS4_I2C_MEM_SIZE 0x14
diff --git a/hw/i2c/mpc_i2c.c b/hw/i2c/mpc_i2c.c
index 156a25a8e9..720d2331e9 100644
--- a/hw/i2c/mpc_i2c.c
+++ b/hw/i2c/mpc_i2c.c
@@ -37,9 +37,7 @@
#endif
#define TYPE_MPC_I2C "mpc-i2c"
-typedef struct MPCI2CState MPCI2CState;
-DECLARE_INSTANCE_CHECKER(MPCI2CState, MPC_I2C,
- TYPE_MPC_I2C)
+OBJECT_DECLARE_SIMPLE_TYPE(MPCI2CState, MPC_I2C)
#define MPC_I2C_ADR 0x00
#define MPC_I2C_FDR 0x04
diff --git a/hw/i2c/smbus_eeprom.c b/hw/i2c/smbus_eeprom.c
index c6777844cf..4d2bf99207 100644
--- a/hw/i2c/smbus_eeprom.c
+++ b/hw/i2c/smbus_eeprom.c
@@ -37,9 +37,7 @@
#define TYPE_SMBUS_EEPROM "smbus-eeprom"
-typedef struct SMBusEEPROMDevice SMBusEEPROMDevice;
-DECLARE_INSTANCE_CHECKER(SMBusEEPROMDevice, SMBUS_EEPROM,
- TYPE_SMBUS_EEPROM)
+OBJECT_DECLARE_SIMPLE_TYPE(SMBusEEPROMDevice, SMBUS_EEPROM)
#define SMBUS_EEPROM_SIZE 256
diff --git a/hw/i2c/smbus_ich9.c b/hw/i2c/smbus_ich9.c
index 2d4578511d..44dd5653b7 100644
--- a/hw/i2c/smbus_ich9.c
+++ b/hw/i2c/smbus_ich9.c
@@ -30,9 +30,7 @@
#include "hw/i386/ich9.h"
#include "qom/object.h"
-typedef struct ICH9SMBState ICH9SMBState;
-DECLARE_INSTANCE_CHECKER(ICH9SMBState, ICH9_SMB_DEVICE,
- TYPE_ICH9_SMB_DEVICE)
+OBJECT_DECLARE_SIMPLE_TYPE(ICH9SMBState, ICH9_SMB_DEVICE)
struct ICH9SMBState {
PCIDevice dev;