Patchwork [11/32] qdev/prop: convert iommu.c to helper macros.

login
register
mail settings
Submitter Gerd Hoffmann
Date Aug. 3, 2009, 3:35 p.m.
Message ID <1249313748-6459-12-git-send-email-kraxel@redhat.com>
Download mbox | patch
Permalink /patch/30621/
State Superseded
Headers show

Comments

Gerd Hoffmann - Aug. 3, 2009, 3:35 p.m.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
 hw/iommu.c |    8 ++------
 1 files changed, 2 insertions(+), 6 deletions(-)

Patch

diff --git a/hw/iommu.c b/hw/iommu.c
index d73dad3..a1c54f8 100644
--- a/hw/iommu.c
+++ b/hw/iommu.c
@@ -404,12 +404,8 @@  static SysBusDeviceInfo iommu_info = {
     .qdev.name  = "iommu",
     .qdev.size  = sizeof(IOMMUState),
     .qdev.props = (Property[]) {
-        {
-            .name = "version",
-            .info = &qdev_prop_hex32,
-            .offset = offsetof(IOMMUState, version),
-        },
-        {/* end of property list */}
+        DEFINE_PROP_HEX32("version", IOMMUState, version, 0),
+        DEFINE_PROP_END_OF_LIST(),
     }
 };