aboutsummaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorCédric Le Goater <clg@kaod.org>2019-10-03 16:36:17 +0200
committerDavid Gibson <david@gibson.dropbear.id.au>2019-10-04 19:08:23 +1000
commit1aba8716c8335e88b8c358002a6e1ac89f7dd258 (patch)
tree6a3c58005b70fd9d25d5cb0dc473645a3d66adbb /hw
parentf478d9af213f169449f7aaba7257aba1a4032e1e (diff)
downloadqemu-1aba8716c8335e88b8c358002a6e1ac89f7dd258.zip
qemu-1aba8716c8335e88b8c358002a6e1ac89f7dd258.tar.gz
qemu-1aba8716c8335e88b8c358002a6e1ac89f7dd258.tar.bz2
ppc/pnv: Remove the XICSFabric Interface from the POWER9 machine
The POWER8 PowerNV machine needs to implement a XICSFabric interface as this is the POWER8 interrupt controller model. But the POWER9 machine uselessly inherits of XICSFabric from the common PowerNV machine definition. Open code machine definitions to have a better control on the different interfaces each machine should define. Fixes: f30c843ced50 ("ppc/pnv: Introduce PowerNV machines with fixed CPU models") Signed-off-by: Cédric Le Goater <clg@kaod.org> Message-Id: <20191003143617.21682-1-clg@kaod.org> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'hw')
-rw-r--r--hw/ppc/pnv.c31
1 files changed, 14 insertions, 17 deletions
diff --git a/hw/ppc/pnv.c b/hw/ppc/pnv.c
index 77a86c6..7cf64b6 100644
--- a/hw/ppc/pnv.c
+++ b/hw/ppc/pnv.c
@@ -1485,23 +1485,21 @@ static void pnv_machine_class_init(ObjectClass *oc, void *data)
.parent = TYPE_PNV9_CHIP, \
}
-#define DEFINE_PNV_MACHINE_TYPE(cpu, class_initfn) \
- { \
- .name = MACHINE_TYPE_NAME(cpu), \
- .parent = TYPE_PNV_MACHINE, \
- .instance_size = sizeof(PnvMachineState), \
- .instance_init = pnv_machine_instance_init, \
- .class_init = class_initfn, \
- .interfaces = (InterfaceInfo[]) { \
- { TYPE_XICS_FABRIC }, \
- { TYPE_INTERRUPT_STATS_PROVIDER }, \
- { }, \
- }, \
- }
-
static const TypeInfo types[] = {
- DEFINE_PNV_MACHINE_TYPE("powernv8", pnv_machine_power8_class_init),
- DEFINE_PNV_MACHINE_TYPE("powernv9", pnv_machine_power9_class_init),
+ {
+ .name = MACHINE_TYPE_NAME("powernv9"),
+ .parent = TYPE_PNV_MACHINE,
+ .class_init = pnv_machine_power9_class_init,
+ },
+ {
+ .name = MACHINE_TYPE_NAME("powernv8"),
+ .parent = TYPE_PNV_MACHINE,
+ .class_init = pnv_machine_power8_class_init,
+ .interfaces = (InterfaceInfo[]) {
+ { TYPE_XICS_FABRIC },
+ { },
+ },
+ },
{
.name = TYPE_PNV_MACHINE,
.parent = TYPE_MACHINE,
@@ -1510,7 +1508,6 @@ static const TypeInfo types[] = {
.instance_init = pnv_machine_instance_init,
.class_init = pnv_machine_class_init,
.interfaces = (InterfaceInfo[]) {
- { TYPE_XICS_FABRIC },
{ TYPE_INTERRUPT_STATS_PROVIDER },
{ },
},