[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 33/53] xics: Minor fixes for XICSFabric interface
From: |
David Gibson |
Subject: |
[PULL 33/53] xics: Minor fixes for XICSFabric interface |
Date: |
Fri, 4 Oct 2019 19:37:27 +1000 |
Interface instances should never be directly dereferenced. So, the common
practice is to make them incomplete types to make sure no-one does that.
XICSFrabric, however, had a dummy type which is less safe.
We were also using OBJECT_CHECK() where we should have been using
INTERFACE_CHECK().
Signed-off-by: David Gibson <address@hidden>
Reviewed-by: Greg Kurz <address@hidden>
Reviewed-by: Cédric Le Goater <address@hidden>
---
include/hw/ppc/xics.h | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/include/hw/ppc/xics.h b/include/hw/ppc/xics.h
index 64a2c8862a..faa33ae943 100644
--- a/include/hw/ppc/xics.h
+++ b/include/hw/ppc/xics.h
@@ -147,13 +147,9 @@ struct ICSIRQState {
uint8_t flags;
};
-struct XICSFabric {
- Object parent;
-};
-
#define TYPE_XICS_FABRIC "xics-fabric"
#define XICS_FABRIC(obj) \
- OBJECT_CHECK(XICSFabric, (obj), TYPE_XICS_FABRIC)
+ INTERFACE_CHECK(XICSFabric, (obj), TYPE_XICS_FABRIC)
#define XICS_FABRIC_CLASS(klass) \
OBJECT_CLASS_CHECK(XICSFabricClass, (klass), TYPE_XICS_FABRIC)
#define XICS_FABRIC_GET_CLASS(obj) \
--
2.21.0
- [PULL 19/53] spapr: Do not put empty properties for -kernel/-initrd/-append, (continued)
- [PULL 19/53] spapr: Do not put empty properties for -kernel/-initrd/-append, David Gibson, 2019/10/04
- [PULL 28/53] target/ppc: remove unnecessary if() around calls to set_dfp{64, 128}() in DFP macros, David Gibson, 2019/10/04
- [PULL 32/53] spapr/xive: skip partially initialized vCPUs in presenter, David Gibson, 2019/10/04
- [PULL 22/53] target/ppc: introduce get_dfp{64, 128}() helper functions, David Gibson, 2019/10/04
- [PULL 25/53] target/ppc: introduce dfp_finalize_decimal{64, 128}() helper functions, David Gibson, 2019/10/04
- [PULL 29/53] spapr-pci: Stop providing assigned-addresses, David Gibson, 2019/10/04
- [PULL 30/53] spapr: Render full FDT on ibm, client-architecture-support, David Gibson, 2019/10/04
- [PULL 27/53] target/ppc: use existing VsrD() macro to eliminate HI_IDX and LO_IDX from dfp_helper.c, David Gibson, 2019/10/04
- [PULL 31/53] target/ppc: use Vsr macros in BCD helpers, David Gibson, 2019/10/04
- [PULL 23/53] target/ppc: introduce set_dfp{64, 128}() helper functions, David Gibson, 2019/10/04
- [PULL 33/53] xics: Minor fixes for XICSFabric interface,
David Gibson <=
- [PULL 35/53] xics: Rename misleading ics_simple_*() functions, David Gibson, 2019/10/04
- [PULL 37/53] xics: Merge TYPE_ICS_BASE and TYPE_ICS_SIMPLE classes, David Gibson, 2019/10/04
- [PULL 36/53] xics: Eliminate reset hook, David Gibson, 2019/10/04
- [PULL 34/53] xics: Eliminate 'reject', 'resend' and 'eoi' class hooks, David Gibson, 2019/10/04
- [PULL 42/53] spapr: Eliminate nr_irqs parameter to SpaprIrq::init, David Gibson, 2019/10/04
- [PULL 38/53] xics: Create sPAPR specific ICS subtype, David Gibson, 2019/10/04
- [PULL 40/53] spapr: Replace spapr_vio_qirq() helper with spapr_vio_irq_pulse() helper, David Gibson, 2019/10/04
- [PULL 39/53] spapr: Fold spapr_phb_lsi_qirq() into its single caller, David Gibson, 2019/10/04
- [PULL 43/53] spapr: Fix indexing of XICS irqs, David Gibson, 2019/10/04
- [PULL 46/53] spapr: Remove unhelpful tracepoints from spapr_irq_free_xics(), David Gibson, 2019/10/04