浏览代码

qdev/prop: convert slavio_intctl.c to helper macros.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id: 
Message-Id:
Gerd Hoffmann 16 年之前
父节点
当前提交
7fdaf611a5
共有 1 个文件被更改,包括 2 次插入6 次删除
  1. 2 6
      hw/slavio_intctl.c

+ 2 - 6
hw/slavio_intctl.c

@@ -425,12 +425,8 @@ static SysBusDeviceInfo slavio_intctl_info = {
     .qdev.name  = "slavio_intctl",
     .qdev.name  = "slavio_intctl",
     .qdev.size  = sizeof(SLAVIO_INTCTLState),
     .qdev.size  = sizeof(SLAVIO_INTCTLState),
     .qdev.props = (Property[]) {
     .qdev.props = (Property[]) {
-        {
-            .name = "cputimer_bit",
-            .info = &qdev_prop_uint32,
-            .offset = offsetof(SLAVIO_INTCTLState, cputimer_bit),
-        },
-        {/* end of property list */}
+        DEFINE_PROP_UINT32("cputimer_bit", SLAVIO_INTCTLState, cputimer_bit, 0),
+        DEFINE_PROP_END_OF_LIST(),
     }
     }
 };
 };