aboutsummaryrefslogtreecommitdiff
path: root/include/hw/hyperv
diff options
context:
space:
mode:
Diffstat (limited to 'include/hw/hyperv')
-rw-r--r--include/hw/hyperv/vmbus-bridge.h3
-rw-r--r--include/hw/hyperv/vmbus.h11
2 files changed, 6 insertions, 8 deletions
diff --git a/include/hw/hyperv/vmbus-bridge.h b/include/hw/hyperv/vmbus-bridge.h
index d090d46..1324873 100644
--- a/include/hw/hyperv/vmbus-bridge.h
+++ b/include/hw/hyperv/vmbus-bridge.h
@@ -25,7 +25,8 @@ struct VMBusBridge {
};
typedef struct VMBusBridge VMBusBridge;
-#define VMBUS_BRIDGE(obj) OBJECT_CHECK(VMBusBridge, (obj), TYPE_VMBUS_BRIDGE)
+DECLARE_INSTANCE_CHECKER(VMBusBridge, VMBUS_BRIDGE,
+ TYPE_VMBUS_BRIDGE)
static inline VMBusBridge *vmbus_bridge_find(void)
{
diff --git a/include/hw/hyperv/vmbus.h b/include/hw/hyperv/vmbus.h
index 282399b..0fe3d3b 100644
--- a/include/hw/hyperv/vmbus.h
+++ b/include/hw/hyperv/vmbus.h
@@ -22,16 +22,13 @@
typedef struct VMBusDevice VMBusDevice;
typedef struct VMBusDeviceClass VMBusDeviceClass;
-#define VMBUS_DEVICE(obj) \
- OBJECT_CHECK(VMBusDevice, (obj), TYPE_VMBUS_DEVICE)
-#define VMBUS_DEVICE_CLASS(klass) \
- OBJECT_CLASS_CHECK(VMBusDeviceClass, (klass), TYPE_VMBUS_DEVICE)
-#define VMBUS_DEVICE_GET_CLASS(obj) \
- OBJECT_GET_CLASS(VMBusDeviceClass, (obj), TYPE_VMBUS_DEVICE)
+DECLARE_OBJ_CHECKERS(VMBusDevice, VMBusDeviceClass,
+ VMBUS_DEVICE, TYPE_VMBUS_DEVICE)
#define TYPE_VMBUS "vmbus"
typedef struct VMBus VMBus;
-#define VMBUS(obj) OBJECT_CHECK(VMBus, (obj), TYPE_VMBUS)
+DECLARE_INSTANCE_CHECKER(VMBus, VMBUS,
+ TYPE_VMBUS)
/*
* Object wrapping a GPADL -- GPA Descriptor List -- an array of guest physical