Start pci hose scan from hose->current_busno.
Ensure hose->current_busno is not less than first_busno. This fixes broken board code which leaves current_busno=0 when first_busno is greater than 0 for the cases with multiple controllers. Signed-off-by: Ed Swarthout <Ed.Swarthout@freescale.com>
This commit is contained in:

committed by
Wolfgang Denk

parent
3865b1fb78
commit
40e81addab
@@ -490,10 +490,16 @@ int pci_hose_scan_bus(struct pci_controller *hose, int bus)
|
|||||||
|
|
||||||
int pci_hose_scan(struct pci_controller *hose)
|
int pci_hose_scan(struct pci_controller *hose)
|
||||||
{
|
{
|
||||||
|
/* Start scan at current_busno.
|
||||||
|
* PCIe will start scan at first_busno+1.
|
||||||
|
*/
|
||||||
|
/* For legacy support, ensure current>=first */
|
||||||
|
if (hose->first_busno > hose->current_busno)
|
||||||
|
hose->current_busno = hose->first_busno;
|
||||||
#ifdef CONFIG_PCI_PNP
|
#ifdef CONFIG_PCI_PNP
|
||||||
pciauto_config_init(hose);
|
pciauto_config_init(hose);
|
||||||
#endif
|
#endif
|
||||||
return pci_hose_scan_bus(hose, hose->first_busno);
|
return pci_hose_scan_bus(hose, hose->current_busno);
|
||||||
}
|
}
|
||||||
|
|
||||||
void pci_init(void)
|
void pci_init(void)
|
||||||
|
Reference in New Issue
Block a user