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
This commit is contained in:
Satoshi Asami 1996-06-09 11:58:19 +00:00
parent db0b35d139
commit 58e025d580
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=16248
2 changed files with 8 additions and 4 deletions

View file

@ -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;

View file

@ -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;