summary refs log tree commit diff stats
path: root/hw/misc/slavio_misc.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/misc/slavio_misc.c')
-rw-r--r--hw/misc/slavio_misc.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/hw/misc/slavio_misc.c b/hw/misc/slavio_misc.c
index 279b38dfc7..f1a039b5a9 100644
--- a/hw/misc/slavio_misc.c
+++ b/hw/misc/slavio_misc.c
@@ -29,6 +29,7 @@
 #include "qemu/module.h"
 #include "sysemu/runstate.h"
 #include "trace.h"
+#include "qom/object.h"
 
 /*
  * This is the auxio port, chip control and system control part of
@@ -39,9 +40,10 @@
  */
 
 #define TYPE_SLAVIO_MISC "slavio_misc"
+typedef struct MiscState MiscState;
 #define SLAVIO_MISC(obj) OBJECT_CHECK(MiscState, (obj), TYPE_SLAVIO_MISC)
 
-typedef struct MiscState {
+struct MiscState {
     SysBusDevice parent_obj;
 
     MemoryRegion cfg_iomem;
@@ -59,17 +61,18 @@ typedef struct MiscState {
     uint8_t diag, mctrl;
     uint8_t sysctrl;
     uint16_t leds;
-} MiscState;
+};
 
 #define TYPE_APC "apc"
+typedef struct APCState APCState;
 #define APC(obj) OBJECT_CHECK(APCState, (obj), TYPE_APC)
 
-typedef struct APCState {
+struct APCState {
     SysBusDevice parent_obj;
 
     MemoryRegion iomem;
     qemu_irq cpu_halt;
-} APCState;
+};
 
 #define MISC_SIZE 1
 #define LED_SIZE 2