summary refs log tree commit diff stats
path: root/include/hw/char/bcm2835_aux.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/hw/char/bcm2835_aux.h')
-rw-r--r--include/hw/char/bcm2835_aux.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/include/hw/char/bcm2835_aux.h b/include/hw/char/bcm2835_aux.h
index 934acf9c81..a08795c47f 100644
--- a/include/hw/char/bcm2835_aux.h
+++ b/include/hw/char/bcm2835_aux.h
@@ -11,13 +11,16 @@
 
 #include "hw/sysbus.h"
 #include "chardev/char-fe.h"
+#include "qom/object.h"
 
 #define TYPE_BCM2835_AUX "bcm2835-aux"
-#define BCM2835_AUX(obj) OBJECT_CHECK(BCM2835AuxState, (obj), TYPE_BCM2835_AUX)
+typedef struct BCM2835AuxState BCM2835AuxState;
+DECLARE_INSTANCE_CHECKER(BCM2835AuxState, BCM2835_AUX,
+                         TYPE_BCM2835_AUX)
 
 #define BCM2835_AUX_RX_FIFO_LEN 8
 
-typedef struct {
+struct BCM2835AuxState {
     /*< private >*/
     SysBusDevice parent_obj;
     /*< public >*/
@@ -29,6 +32,6 @@ typedef struct {
     uint8_t read_fifo[BCM2835_AUX_RX_FIFO_LEN];
     uint8_t read_pos, read_count;
     uint8_t ier, iir;
-} BCM2835AuxState;
+};
 
 #endif