2 * ASPEED I3C Controller
4 * Copyright (C) 2021 ASPEED Technology Inc.
6 * This code is licensed under the GPL version 2 or later. See
7 * the COPYING file in the top-level directory.
13 #include "hw/sysbus.h"
15 #define TYPE_ASPEED_I3C "aspeed.i3c"
16 #define TYPE_ASPEED_I3C_DEVICE "aspeed.i3c.device"
17 OBJECT_DECLARE_TYPE(AspeedI3CState
, AspeedI3CClass
, ASPEED_I3C
)
19 #define ASPEED_I3C_NR_REGS (0x70 >> 2)
20 #define ASPEED_I3C_DEVICE_NR_REGS (0x300 >> 2)
21 #define ASPEED_I3C_NR_DEVICES 6
23 OBJECT_DECLARE_SIMPLE_TYPE(AspeedI3CDevice
, ASPEED_I3C_DEVICE
)
24 typedef struct AspeedI3CDevice
{
33 uint32_t regs
[ASPEED_I3C_DEVICE_NR_REGS
];
36 typedef struct AspeedI3CState
{
42 MemoryRegion iomem_container
;
45 uint32_t regs
[ASPEED_I3C_NR_REGS
];
46 AspeedI3CDevice devices
[ASPEED_I3C_NR_DEVICES
];
48 #endif /* ASPEED_I3C_H */