aboutsummaryrefslogtreecommitdiff
path: root/src/devices
diff options
context:
space:
mode:
Diffstat (limited to 'src/devices')
-rw-r--r--src/devices/device_util.c10
-rw-r--r--src/devices/pci_device.c12
2 files changed, 17 insertions, 5 deletions
diff --git a/src/devices/device_util.c b/src/devices/device_util.c
index a2741e3e98..979b025324 100644
--- a/src/devices/device_util.c
+++ b/src/devices/device_util.c
@@ -139,9 +139,15 @@ const char *dev_path(device_t dev)
memcpy(buffer, "Root Device", 12);
break;
case DEVICE_PATH_PCI:
+#if PCI_BUS_SEGN_BITS
+ sprintf(buffer, "PCI: %04x:%02x:%02x.%01x",
+ dev->bus->secondary>>8, dev->bus->secondary & 0xff,
+ PCI_SLOT(dev->path.u.pci.devfn), PCI_FUNC(dev->path.u.pci.devfn));
+#else
sprintf(buffer, "PCI: %02x:%02x.%01x",
dev->bus->secondary,
PCI_SLOT(dev->path.u.pci.devfn), PCI_FUNC(dev->path.u.pci.devfn));
+#endif
break;
case DEVICE_PATH_PNP:
sprintf(buffer, "PNP: %04x.%01x",
@@ -430,7 +436,11 @@ void report_resource_stored(device_t dev, struct resource *resource, const char
end = resource_end(resource);
buf[0] = '\0';
if (resource->flags & IORESOURCE_PCI_BRIDGE) {
+#if PCI_BUS_SEGN_BITS
+ sprintf(buf, "bus %04x:%02x ", dev->bus->secondary>>8, dev->link[0].secondary & 0xff);
+#else
sprintf(buf, "bus %02x ", dev->link[0].secondary);
+#endif
}
printk_debug(
"%s %02x <- [0x%010Lx - 0x%010Lx] %s%s%s\n",
diff --git a/src/devices/pci_device.c b/src/devices/pci_device.c
index 2a7502b280..2750893378 100644
--- a/src/devices/pci_device.c
+++ b/src/devices/pci_device.c
@@ -761,9 +761,7 @@ static void set_pci_ops(struct device *dev)
return;
}
- printk_debug("%s: seeking driver for %x:%x class %x\n",
- __FUNCTION__, dev->vendor, dev->device, dev->class);
- /* Look through the list of setup drivers and find one for
+ /* Look through the list of setup drivers and find one for
* this pci device
*/
for(driver = &pci_drivers[0]; driver != &epci_drivers[0]; driver++) {
@@ -1004,7 +1002,11 @@ unsigned int pci_scan_bus(struct bus *bus,
device_t old_devices;
device_t child;
- printk_debug("PCI: pci_scan_bus for bus %d\n", bus->secondary);
+#if PCI_BUS_SEGN_BITS
+ printk_debug("PCI: pci_scan_bus for bus %04x:%02x\n", bus->secondary >> 8, bus->secondary & 0xff);
+#else
+ printk_debug("PCI: pci_scan_bus for bus %02x\n", bus->secondary);
+#endif
old_devices = bus->children;
bus->children = 0;
@@ -1062,7 +1064,7 @@ unsigned int pci_scan_bus(struct bus *bus,
*
* Return how far we've got finding sub-buses.
*/
- printk_debug("PCI: pci_scan_bus returning with max=%02x\n", max);
+ printk_debug("PCI: pci_scan_bus returning with max=%03x\n", max);
post_code(0x55);
return max;
}