Commit 87c4ac84 authored by Michael Buesch's avatar Michael Buesch Committed by David S. Miller

ssb: Fix probing of PCI cores if PCI and PCIE core is available

This will make sure that always the correct core is selected, even if
there are both a PCI and PCI-E core on a PCI or PCI-E card.
Signed-off-by: default avatarMichael Buesch <mb@bu3sch.de>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 4ec24119
...@@ -388,6 +388,17 @@ int ssb_bus_scan(struct ssb_bus *bus, ...@@ -388,6 +388,17 @@ int ssb_bus_scan(struct ssb_bus *bus,
case SSB_DEV_PCI: case SSB_DEV_PCI:
case SSB_DEV_PCIE: case SSB_DEV_PCIE:
#ifdef CONFIG_SSB_DRIVER_PCICORE #ifdef CONFIG_SSB_DRIVER_PCICORE
if (bus->bustype == SSB_BUSTYPE_PCI) {
/* Ignore PCI cores on PCI-E cards.
* Ignore PCI-E cores on PCI cards. */
if (dev->id.coreid == SSB_DEV_PCI) {
if (bus->host_pci->is_pcie)
continue;
} else {
if (!bus->host_pci->is_pcie)
continue;
}
}
if (bus->pcicore.dev) { if (bus->pcicore.dev) {
ssb_printk(KERN_WARNING PFX ssb_printk(KERN_WARNING PFX
"WARNING: Multiple PCI(E) cores found\n"); "WARNING: Multiple PCI(E) cores found\n");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment