[RFC PATCH v2 126/137] hw/pci-host/raven: Parent the OR-IRQ under the host bridge

Alexander Graf <[email protected]>
Newsgroups org.nongnu.qemu-arm,org.nongnu.qemu-devel,org.nongnu.qemu-riscv
Message-ID <[email protected]>
The PReP raven host bridge creates an or-irq gate to fan PCI
interrupts into IRQ 15.  Parent it under the host bridge so it
gets a canonical path.

AI-used-for: code (refactoring)
Signed-off-by: Alexander Graf <[email protected]>
---
 hw/pci-host/raven.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/hw/pci-host/raven.c b/hw/pci-host/raven.c
index b6ab686ff5..62d78efde5 100644
--- a/hw/pci-host/raven.c
+++ b/hw/pci-host/raven.c
@@ -249,7 +249,8 @@ static void raven_pcihost_realizefn(DeviceState *d, Error **errp)
      * According to PReP specification section 6.1.6 "System Interrupt
      * Assignments", all PCI interrupts are routed via IRQ 15
      */
-    s->or_irq = OR_IRQ(object_new(TYPE_OR_IRQ));
+    s->or_irq = OR_IRQ(object_new_child(OBJECT(s), "or-irq",
+                                        TYPE_OR_IRQ));
     object_property_set_int(OBJECT(s->or_irq), "num-lines", PCI_NUM_PINS,
                             &error_fatal);
     qdev_realize(DEVICE(s->or_irq), NULL, &error_fatal);
-- 
2.47.1
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.