diff options
Diffstat (limited to 'hw/misc/milkymist-pfpu.c')
-rw-r--r-- | hw/misc/milkymist-pfpu.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/hw/misc/milkymist-pfpu.c b/hw/misc/milkymist-pfpu.c index 516825e83d..489bb8873f 100644 --- a/hw/misc/milkymist-pfpu.c +++ b/hw/misc/milkymist-pfpu.c @@ -31,6 +31,7 @@ #include "qemu/module.h" #include "qemu/error-report.h" #include <math.h> +#include "qom/object.h" /* #define TRACE_EXEC */ @@ -120,8 +121,9 @@ static const char *opcode_to_str[] = { #endif #define TYPE_MILKYMIST_PFPU "milkymist-pfpu" -#define MILKYMIST_PFPU(obj) \ - OBJECT_CHECK(MilkymistPFPUState, (obj), TYPE_MILKYMIST_PFPU) +typedef struct MilkymistPFPUState MilkymistPFPUState; +DECLARE_INSTANCE_CHECKER(MilkymistPFPUState, MILKYMIST_PFPU, + TYPE_MILKYMIST_PFPU) struct MilkymistPFPUState { SysBusDevice parent_obj; @@ -137,7 +139,6 @@ struct MilkymistPFPUState { int output_queue_pos; uint32_t output_queue[MAX_LATENCY]; }; -typedef struct MilkymistPFPUState MilkymistPFPUState; static inline uint32_t get_dma_address(uint32_t base, uint32_t x, uint32_t y) |