Since revision 845, we had a really loud error message in the coreboot boot log at least on qemu: ERROR: pci_scan_bus called with incorrect bus->dev->path.type, path is PCI_DOMAIN: 0000 Since this means we completely ignore the static device tree, upgrade the error message to die().
A port with a bug in the PCI scan code should not be allowed to keep people scratching their heads about why the static device tree and associated settings are ignored. Instead, the boot should fail loudly.
This will break booting at least on qemu. Try applying it if your target shows any PCI/HT related funnies.
Signed-off-by: Carl-Daniel Hailfinger c-d.hailfinger.devel.2006@gmx.net
Index: corebootv3-pci_scan_bus_die/device/pci_device.c =================================================================== --- corebootv3-pci_scan_bus_die/device/pci_device.c (Revision 951) +++ corebootv3-pci_scan_bus_die/device/pci_device.c (Arbeitskopie) @@ -1101,9 +1101,11 @@
printk(BIOS_DEBUG, "%s start bus %p, bus->dev %p\n", __func__, bus, bus->dev); - if (bus->dev->path.type != DEVICE_PATH_PCI_BUS) + if (bus->dev->path.type != DEVICE_PATH_PCI_BUS) { printk(BIOS_ERR, "ERROR: pci_scan_bus called with incorrect " "bus->dev->path.type, path is %s\n", dev_path(bus->dev)); + die("The PCI scan code is broken"); + }
#if PCI_BUS_SEGN_BITS printk(BIOS_DEBUG, "PCI: pci_scan_bus for bus %04x:%02x\n",
Carl-Daniel Hailfinger wrote:
This will break booting at least on qemu. Try applying it if your target shows any PCI/HT related funnies.
Signed-off-by: Carl-Daniel Hailfinger c-d.hailfinger.devel.2006@gmx.net
Nak at least from me.
die("The PCI scan code is broken");
This is not a very useful message. Even if it was improved I don't think die() is the right approach to solving this problem.
Better investigate what's going on and then attack it with solutions, rather than burying head in sand.
//Peter
I'm not anxious to break working targets, even if they work due to a bug.
Let's fix it. This is not what we want to do.
ron