From c19d6a6ce59873f2326b14bb4af69048cceb9300 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ky=C3=B6sti=20M=C3=A4lkki?= Date: Thu, 4 Jul 2019 21:39:28 +0300 Subject: device/pci: Replace use of dev_find_slot() for IRQs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I48c0de73338430282ce1a4442bbeb7c867dc174c Signed-off-by: Kyösti Mälkki Reviewed-on: https://review.coreboot.org/c/coreboot/+/34079 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Georgi --- src/mainboard/emulation/qemu-i440fx/mainboard.c | 2 +- src/mainboard/emulation/qemu-q35/mainboard.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src/mainboard') diff --git a/src/mainboard/emulation/qemu-i440fx/mainboard.c b/src/mainboard/emulation/qemu-i440fx/mainboard.c index 4886fe1830..0b3689731e 100644 --- a/src/mainboard/emulation/qemu-i440fx/mainboard.c +++ b/src/mainboard/emulation/qemu-i440fx/mainboard.c @@ -41,7 +41,7 @@ static void qemu_nb_init(struct device *dev) /* setup IRQ routing */ for (i = 0; i < 32; i++) - pci_assign_irqs(0, i, qemu_i440fx_irqs + (i % 4)); + pci_assign_irqs(pcidev_on_root(i, 0), qemu_i440fx_irqs + (i % 4)); } static struct device_operations nb_operations = { diff --git a/src/mainboard/emulation/qemu-q35/mainboard.c b/src/mainboard/emulation/qemu-q35/mainboard.c index 90a32f4000..ae3f96a158 100644 --- a/src/mainboard/emulation/qemu-q35/mainboard.c +++ b/src/mainboard/emulation/qemu-q35/mainboard.c @@ -61,10 +61,10 @@ static void qemu_nb_init(struct device *dev) /* setup IRQ routing for pci slots */ for (i = 0; i < 25; i++) - pci_assign_irqs(0, i, qemu_q35_irqs + (i % 4)); + pci_assign_irqs(pcidev_on_root(i, 0), qemu_q35_irqs + (i % 4)); /* setup IRQ routing southbridge devices */ for (i = 25; i < 32; i++) - pci_assign_irqs(0, i, qemu_q35_irqs); + pci_assign_irqs(pcidev_on_root(i, 0), qemu_q35_irqs); } static void qemu_nb_read_resources(struct device *dev) -- cgit v1.2.3