diff options
author | Marcel Apfelbaum <marcel.a@redhat.com> | 2015-02-16 19:29:19 +0200 |
---|---|---|
committer | Gerd Hoffmann <kraxel@redhat.com> | 2015-03-12 08:17:15 +0100 |
commit | ac1e2b439cac0c94142abc823c8ce4f54942629a (patch) | |
tree | 799dd21ea46d270bf72aa2f373838e188ffb58cb | |
parent | 94c9a7ca9c962f8664e60ed6b5c523f6fe16b5c8 (diff) | |
download | seabios-ac1e2b439cac0c94142abc823c8ce4f54942629a.zip seabios-ac1e2b439cac0c94142abc823c8ce4f54942629a.tar.gz seabios-ac1e2b439cac0c94142abc823c8ce4f54942629a.tar.bz2 |
fw/pci: scan all buses if extraroots romfile is present
If there are extra primary root buses, scanning the bus's 0
subtree is not enough. Scan all the range.
Signed-off-by: Marcel Apfelbaum <marcel@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
(cherry picked from commit 5cc7eece39721f20b417770374a4112c454be801)
-rw-r--r-- | src/fw/pciinit.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/fw/pciinit.c b/src/fw/pciinit.c index 3e6308a..43c6e2f 100644 --- a/src/fw/pciinit.c +++ b/src/fw/pciinit.c @@ -490,8 +490,17 @@ pci_bios_init_bus_rec(int bus, u8 *pci_bus) static void pci_bios_init_bus(void) { + u8 extraroots = romfile_loadint("etc/extra-pci-roots", 0); u8 pci_bus = 0; + pci_bios_init_bus_rec(0 /* host bus */, &pci_bus); + + if (extraroots) { + while (pci_bus < 0xff) { + pci_bus++; + pci_bios_init_bus_rec(pci_bus, &pci_bus); + } + } } |