diff options
author | Cédric Le Goater | 2017-02-27 15:29:25 +0100 |
---|---|---|
committer | David Gibson | 2017-03-01 01:23:39 +0100 |
commit | b4f27d71e3c98c9c4590de40d478004b8482b277 (patch) | |
tree | 1a0911790ac3ba7967980320fd975739b77346f3 /include/hw | |
parent | ppc/xics: move the cpu_setup() handler under the ICPState class (diff) | |
download | qemu-b4f27d71e3c98c9c4590de40d478004b8482b277.tar.gz qemu-b4f27d71e3c98c9c4590de40d478004b8482b277.tar.xz qemu-b4f27d71e3c98c9c4590de40d478004b8482b277.zip |
ppc/xics: use the QOM interface to grab an ICP
Also introduce a xics_icp_get() helper to simplify the changes.
Signed-off-by: Cédric Le Goater <clg@kaod.org>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'include/hw')
-rw-r--r-- | include/hw/ppc/xics.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/include/hw/ppc/xics.h b/include/hw/ppc/xics.h index d17f62c5cc..c57e80e418 100644 --- a/include/hw/ppc/xics.h +++ b/include/hw/ppc/xics.h @@ -151,7 +151,7 @@ struct ICSState { uint32_t offset; qemu_irq *qirqs; ICSIRQState *irqs; - XICSState *xics; + XICSFabric *xics; }; static inline bool ics_valid_irq(ICSState *ics, uint32_t nr) @@ -198,16 +198,16 @@ typedef struct XICSFabricClass { #define XICS_IRQS_SPAPR 1024 -qemu_irq xics_get_qirq(XICSFabric *xi, int irq); - int spapr_ics_alloc(ICSState *ics, int irq_hint, bool lsi, Error **errp); int spapr_ics_alloc_block(ICSState *ics, int num, bool lsi, bool align, Error **errp); void spapr_ics_free(ICSState *ics, int irq, int num); void spapr_dt_xics(XICSState *xics, void *fdt, uint32_t phandle); -void xics_cpu_setup(XICSState *icp, PowerPCCPU *cpu); -void xics_cpu_destroy(XICSState *icp, PowerPCCPU *cpu); +qemu_irq xics_get_qirq(XICSFabric *xi, int irq); +ICPState *xics_icp_get(XICSFabric *xi, int server); +void xics_cpu_setup(XICSFabric *xi, PowerPCCPU *cpu); +void xics_cpu_destroy(XICSFabric *xi, PowerPCCPU *cpu); /* Internal XICS interfaces */ int xics_get_cpu_index_by_dt_id(int cpu_dt_id); |