Don't attach if the bootloader has not indicated that we're a PCI host. This

fixes booting on systems which are PCI targets.
This commit is contained in:
Juli Mallett 2012-10-26 00:04:05 +00:00
parent 93036677b5
commit 452f8dcf7b
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=242103

View File

@ -104,7 +104,9 @@ static uint64_t octopci_cs_addr(unsigned, unsigned, unsigned, unsigned);
static void
octopci_identify(driver_t *drv, device_t parent)
{
/* XXX Check sysinfo flag. */
/* Check whether we are a PCI host. */
if ((cvmx_sysinfo_get()->bootloader_config_flags & CVMX_BOOTINFO_CFG_FLAG_PCI_HOST) == 0)
return;
BUS_ADD_CHILD(parent, 0, "pcib", 0);
if (octeon_has_feature(OCTEON_FEATURE_PCIE))