aboutsummaryrefslogtreecommitdiff
path: root/include/hw/i386
diff options
context:
space:
mode:
authorEduardo Habkost <ehabkost@redhat.com>2020-09-16 14:25:19 -0400
committerEduardo Habkost <ehabkost@redhat.com>2020-09-18 14:12:32 -0400
commit8063396bf3459a810d24e3efd6110b8480f0de5b (patch)
tree40f85f15d7016e3ee66916a59be53d2b2c71510a /include/hw/i386
parenta489d1951cd9cc91c5954214fcf6ae0f9d2d4292 (diff)
Use OBJECT_DECLARE_SIMPLE_TYPE when possible
This converts existing DECLARE_INSTANCE_CHECKER usage to OBJECT_DECLARE_SIMPLE_TYPE when possible. $ ./scripts/codeconverter/converter.py -i \ --pattern=AddObjectDeclareSimpleType $(git grep -l '' -- '*.[ch]') Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> Acked-by: Paul Durrant <paul@xen.org> Message-Id: <20200916182519.415636-6-ehabkost@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Diffstat (limited to 'include/hw/i386')
-rw-r--r--include/hw/i386/ich9.h4
-rw-r--r--include/hw/i386/intel_iommu.h4
2 files changed, 2 insertions, 6 deletions
diff --git a/include/hw/i386/ich9.h b/include/hw/i386/ich9.h
index e750d67975..48b442bc0b 100644
--- a/include/hw/i386/ich9.h
+++ b/include/hw/i386/ich9.h
@@ -24,9 +24,7 @@ void ich9_generate_smi(void);
#define ICH9_CC_SIZE (16 * 1024) /* 16KB. Chipset configuration registers */
#define TYPE_ICH9_LPC_DEVICE "ICH9-LPC"
-typedef struct ICH9LPCState ICH9LPCState;
-DECLARE_INSTANCE_CHECKER(ICH9LPCState, ICH9_LPC_DEVICE,
- TYPE_ICH9_LPC_DEVICE)
+OBJECT_DECLARE_SIMPLE_TYPE(ICH9LPCState, ICH9_LPC_DEVICE)
struct ICH9LPCState {
/* ICH9 LPC PCI to ISA bridge */
diff --git a/include/hw/i386/intel_iommu.h b/include/hw/i386/intel_iommu.h
index 98cfc77723..41783ee46d 100644
--- a/include/hw/i386/intel_iommu.h
+++ b/include/hw/i386/intel_iommu.h
@@ -27,9 +27,7 @@
#include "qom/object.h"
#define TYPE_INTEL_IOMMU_DEVICE "intel-iommu"
-typedef struct IntelIOMMUState IntelIOMMUState;
-DECLARE_INSTANCE_CHECKER(IntelIOMMUState, INTEL_IOMMU_DEVICE,
- TYPE_INTEL_IOMMU_DEVICE)
+OBJECT_DECLARE_SIMPLE_TYPE(IntelIOMMUState, INTEL_IOMMU_DEVICE)
#define TYPE_INTEL_IOMMU_MEMORY_REGION "intel-iommu-iommu-memory-region"