aboutsummaryrefslogtreecommitdiff
path: root/include/hw/sd/allwinner-sdhost.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/hw/sd/allwinner-sdhost.h')
-rw-r--r--include/hw/sd/allwinner-sdhost.h18
1 files changed, 8 insertions, 10 deletions
diff --git a/include/hw/sd/allwinner-sdhost.h b/include/hw/sd/allwinner-sdhost.h
index 839732ebf3..7bccc06d1c 100644
--- a/include/hw/sd/allwinner-sdhost.h
+++ b/include/hw/sd/allwinner-sdhost.h
@@ -45,19 +45,17 @@
* @{
*/
-#define AW_SDHOST(obj) \
- OBJECT_CHECK(AwSdHostState, (obj), TYPE_AW_SDHOST)
-#define AW_SDHOST_CLASS(klass) \
- OBJECT_CLASS_CHECK(AwSdHostClass, (klass), TYPE_AW_SDHOST)
-#define AW_SDHOST_GET_CLASS(obj) \
- OBJECT_GET_CLASS(AwSdHostClass, (obj), TYPE_AW_SDHOST)
+typedef struct AwSdHostClass AwSdHostClass;
+typedef struct AwSdHostState AwSdHostState;
+DECLARE_OBJ_CHECKERS(AwSdHostState, AwSdHostClass,
+ AW_SDHOST, TYPE_AW_SDHOST)
/** @} */
/**
* Allwinner SD Host Controller object instance state.
*/
-typedef struct AwSdHostState {
+struct AwSdHostState {
/*< private >*/
SysBusDevice busdev;
/*< public >*/
@@ -119,7 +117,7 @@ typedef struct AwSdHostState {
/** @} */
-} AwSdHostState;
+};
/**
* Allwinner SD Host Controller class-level struct.
@@ -128,7 +126,7 @@ typedef struct AwSdHostState {
* such that the generic code can use this struct to support
* all devices.
*/
-typedef struct AwSdHostClass {
+struct AwSdHostClass {
/*< private >*/
SysBusDeviceClass parent_class;
/*< public >*/
@@ -136,6 +134,6 @@ typedef struct AwSdHostClass {
/** Maximum buffer size in bytes per DMA descriptor */
size_t max_desc_size;
-} AwSdHostClass;
+};
#endif /* HW_SD_ALLWINNER_SDHOST_H */