summaryrefslogtreecommitdiffstats
path: root/sys/dev
diff options
context:
space:
mode:
authorasami <asami@FreeBSD.org>1996-06-09 11:58:19 +0000
committerasami <asami@FreeBSD.org>1996-06-09 11:58:19 +0000
commit730d4b1272168bc12e16705f8c4a356f6cae892a (patch)
tree53ab06aaf507df694bd5eba52d769c227098dedc /sys/dev
parent2f734506ac8a1ad2611da053852c2367a8fe5b63 (diff)
downloadFreeBSD-src-730d4b1272168bc12e16705f8c4a356f6cae892a.zip
FreeBSD-src-730d4b1272168bc12e16705f8c4a356f6cae892a.tar.gz
Scan PCI buses in order the BIOS has assigned them. This is sometimes
necessary to boot from a SCSI disk connected to a twin-channel adapter, and you have multiple of them (disks and adapters). Reviewed by: se
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/pci/pci.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/dev/pci/pci.c b/sys/dev/pci/pci.c
index cda0bd9..6f37602 100644
--- a/sys/dev/pci/pci.c
+++ b/sys/dev/pci/pci.c
@@ -1,6 +1,6 @@
/**************************************************************************
**
-** $Id: pci.c,v 1.49 1996/04/25 06:04:27 asami Exp $
+** $Id: pci.c,v 1.50 1996/05/18 17:32:20 se Exp $
**
** General subroutines for the PCI bus.
** pci_configure ()
@@ -748,7 +748,8 @@ pci_bus_config (void)
** allocate bus descriptor for bus behind the bridge
*/
link = &pcicb->pcicb_down;
- while (*link) link = &(*link)->pcicb_next;
+ while (*link && (*link)->pcicb_bus < secondary)
+ link = &(*link)->pcicb_next;
this = malloc (sizeof (*this), M_DEVBUF, M_WAITOK);
@@ -758,6 +759,7 @@ pci_bus_config (void)
** scanning the bus behind the bridge.
*/
bzero (this, sizeof(*this));
+ this->pcicb_next = *link;
this->pcicb_up = pcicb;
this->pcicb_bridge = tag;
this->pcicb_bus = secondary;
OpenPOWER on IntegriCloud