aboutsummaryrefslogtreecommitdiff
path: root/hw/i2c
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <philmd@linaro.org>2023-01-10 09:25:07 +0100
committerPeter Maydell <peter.maydell@linaro.org>2023-01-23 13:32:38 +0000
commitf6cf2eb8ec6d2d2e3e5fd51147079228c65833bd (patch)
tree312504b5e21c1daa08b7fb37b0af0a617c4cc982 /hw/i2c
parent550da1cc22c49f0df427232be29484230d15029b (diff)
hw/i2c/versatile_i2c: Use ARM_SBCON_I2C() macro
ARM_SBCON_I2C() macro and ArmSbconI2CState typedef are already declared via the QOM DECLARE_INSTANCE_CHECKER() macro in "hw/i2c/arm_sbcon_i2c.h". Drop the VERSATILE_I2C declarations from versatile_i2c.c. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-id: 20230110082508.24038-5-philmd@linaro.org Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/i2c')
-rw-r--r--hw/i2c/versatile_i2c.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/hw/i2c/versatile_i2c.c b/hw/i2c/versatile_i2c.c
index b95c70608b..d19df62265 100644
--- a/hw/i2c/versatile_i2c.c
+++ b/hw/i2c/versatile_i2c.c
@@ -29,11 +29,6 @@
#include "qemu/module.h"
#include "qom/object.h"
-typedef ArmSbconI2CState VersatileI2CState;
-DECLARE_INSTANCE_CHECKER(ArmSbconI2CState, VERSATILE_I2C,
- TYPE_ARM_SBCON_I2C)
-
-
REG32(CONTROL_GET, 0)
REG32(CONTROL_SET, 0)
@@ -86,7 +81,7 @@ static const MemoryRegionOps versatile_i2c_ops = {
static void versatile_i2c_init(Object *obj)
{
DeviceState *dev = DEVICE(obj);
- ArmSbconI2CState *s = VERSATILE_I2C(obj);
+ ArmSbconI2CState *s = ARM_SBCON_I2C(obj);
SysBusDevice *sbd = SYS_BUS_DEVICE(obj);
I2CBus *bus;