From 25d86d4f29f9712f8602d5768895d210466eb05a Mon Sep 17 00:00:00 2001 From: BALATON Zoltan Date: Thu, 23 Oct 2025 02:06:13 +0200 Subject: [PATCH] hw/ppc/pegasos2: Add south bridge pointer in the machine state MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Add field for the south bridge in machine state to have both north and south bridges in it. Signed-off-by: BALATON Zoltan Reviewed-by: Philippe Mathieu-Daudé Link: https://lore.kernel.org/qemu-devel/654d3223b418d5bb2ba08a2b014375c2abf341aa.1761176219.git.balaton@eik.bme.hu Signed-off-by: Harsh Prateek Bora --- hw/ppc/pegasos2.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/hw/ppc/pegasos2.c b/hw/ppc/pegasos2.c index 9b89c7ecc2..4b63f0e175 100644 --- a/hw/ppc/pegasos2.c +++ b/hw/ppc/pegasos2.c @@ -69,6 +69,7 @@ struct Pegasos2MachineState { PowerPCCPU *cpu; DeviceState *nb; /* north bridge */ + DeviceState *sb; /* south bridge */ IRQState pci_irqs[PCI_NUM_PINS]; OrIRQState orirq[PCI_NUM_PINS]; qemu_irq mv_pirq[PCI_NUM_PINS]; @@ -174,7 +175,8 @@ static void pegasos2_init(MachineState *machine) pci_bus = mv64361_get_pci_bus(pm->nb, 1); /* VIA VT8231 South Bridge (multifunction PCI device) */ - via = OBJECT(pci_new_multifunction(PCI_DEVFN(12, 0), TYPE_VT8231_ISA)); + pm->sb = DEVICE(pci_new_multifunction(PCI_DEVFN(12, 0), TYPE_VT8231_ISA)); + via = OBJECT(pm->sb); /* Set properties on individual devices before realizing the south bridge */ if (machine->audiodev) { -- 2.47.3