[3/4] NUMA-Q: use quad numbers passed to low-level PCI config helpers

William Lee Irwin III (wli@holomorphy.com)
Tue, 12 Nov 2002 04:37:46 -0800


This makes the PCI configuration read/write helpers use their (currently
unused) seg argument as the PCI domain argument.

numa.c | 16 ++++++++--------
1 files changed, 8 insertions(+), 8 deletions(-)

diff -urpN pci-2.5.47-2/arch/i386/pci/numa.c pci-2.5.47-3/arch/i386/pci/numa.c
--- pci-2.5.47-2/arch/i386/pci/numa.c 2002-11-12 03:22:17.000000000 -0800
+++ pci-2.5.47-3/arch/i386/pci/numa.c 2002-11-12 03:25:35.000000000 -0800
@@ -27,17 +27,17 @@ static int __pci_conf1_mq_read (int seg,

spin_lock_irqsave(&pci_config_lock, flags);

- outl_quad(PCI_CONF1_MQ_ADDRESS(bus, dev, fn, reg), 0xCF8, BUS2QUAD(bus));
+ outl_quad(PCI_CONF1_MQ_ADDRESS(bus, dev, fn, reg), 0xCF8, seg);

switch (len) {
case 1:
- *value = inb_quad(0xCFC + (reg & 3), BUS2QUAD(bus));
+ *value = inb_quad(0xCFC + (reg & 3), seg);
break;
case 2:
- *value = inw_quad(0xCFC + (reg & 2), BUS2QUAD(bus));
+ *value = inw_quad(0xCFC + (reg & 2), seg);
break;
case 4:
- *value = inl_quad(0xCFC, BUS2QUAD(bus));
+ *value = inl_quad(0xCFC, seg);
break;
}

@@ -55,17 +55,17 @@ static int __pci_conf1_mq_write (int seg

spin_lock_irqsave(&pci_config_lock, flags);

- outl_quad(PCI_CONF1_MQ_ADDRESS(bus, dev, fn, reg), 0xCF8, BUS2QUAD(bus));
+ outl_quad(PCI_CONF1_MQ_ADDRESS(bus, dev, fn, reg), 0xCF8, seg);

switch (len) {
case 1:
- outb_quad((u8)value, 0xCFC + (reg & 3), BUS2QUAD(bus));
+ outb_quad((u8)value, 0xCFC + (reg & 3), seg);
break;
case 2:
- outw_quad((u16)value, 0xCFC + (reg & 2), BUS2QUAD(bus));
+ outw_quad((u16)value, 0xCFC + (reg & 2), seg);
break;
case 4:
- outl_quad((u32)value, 0xCFC, BUS2QUAD(bus));
+ outl_quad((u32)value, 0xCFC, seg);
break;
}

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/