summaryrefslogtreecommitdiff
path: root/src/device
diff options
context:
space:
mode:
authorAngel Pons <th3fanbus@gmail.com>2021-06-28 11:59:33 +0200
committerPatrick Georgi <pgeorgi@google.com>2021-07-01 09:39:56 +0000
commitceca5dedbc13ddc31df69c0c9d9664c5c2347f19 (patch)
tree2e10f71dca5a5467bd461cbd0d2be7c151724798 /src/device
parent34237863ffb12115d95bdcdd89aeca6edf183ebc (diff)
device/pci_device.c: Reuse `irq` variable
The `irq` variable has the same value as `pIntAtoD[line - 1]`. Change-Id: Iabf760adbc3014b32cfe6f908dc04c38b71bd980 Signed-off-by: Angel Pons <th3fanbus@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/55892 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Paul Menzel <paulepanter@mailbox.org> Reviewed-by: Werner Zeh <werner.zeh@siemens.com>
Diffstat (limited to 'src/device')
-rw-r--r--src/device/pci_device.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/device/pci_device.c b/src/device/pci_device.c
index 36346603cf..63c1dc522a 100644
--- a/src/device/pci_device.c
+++ b/src/device/pci_device.c
@@ -1633,11 +1633,10 @@ void pci_assign_irqs(struct device *dev, const unsigned char pIntAtoD[4])
printk(BIOS_DEBUG, "Assigning IRQ %d to %s\n", irq, dev_path(dev));
- pci_write_config8(dev, PCI_INTERRUPT_LINE, pIntAtoD[line - 1]);
+ pci_write_config8(dev, PCI_INTERRUPT_LINE, irq);
/* Change to level triggered. */
- i8259_configure_irq_trigger(pIntAtoD[line - 1],
- IRQ_LEVEL_TRIGGERED);
+ i8259_configure_irq_trigger(irq, IRQ_LEVEL_TRIGGERED);
}
}