diff options
author | Michael Buesch <mb@bu3sch.de> | 2008-01-03 12:59:25 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-09 02:30:10 -0500 |
commit | 87c4ac841c1d524416ab36c19689550bf302dab1 (patch) | |
tree | 4a1124cba1a76581e5f4bdf970d4ae16003dda67 | |
parent | 4ec2411980d0fd2995e8dea8a06fe57aa47523cb (diff) |
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: Michael Buesch <mb@bu3sch.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | drivers/ssb/scan.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/ssb/scan.c b/drivers/ssb/scan.c index 96258c60919d..63ee5cfbefbb 100644 --- a/drivers/ssb/scan.c +++ b/drivers/ssb/scan.c | |||
@@ -388,6 +388,17 @@ int ssb_bus_scan(struct ssb_bus *bus, | |||
388 | case SSB_DEV_PCI: | 388 | case SSB_DEV_PCI: |
389 | case SSB_DEV_PCIE: | 389 | case SSB_DEV_PCIE: |
390 | #ifdef CONFIG_SSB_DRIVER_PCICORE | 390 | #ifdef CONFIG_SSB_DRIVER_PCICORE |
391 | if (bus->bustype == SSB_BUSTYPE_PCI) { | ||
392 | /* Ignore PCI cores on PCI-E cards. | ||
393 | * Ignore PCI-E cores on PCI cards. */ | ||
394 | if (dev->id.coreid == SSB_DEV_PCI) { | ||
395 | if (bus->host_pci->is_pcie) | ||
396 | continue; | ||
397 | } else { | ||
398 | if (!bus->host_pci->is_pcie) | ||
399 | continue; | ||
400 | } | ||
401 | } | ||
391 | if (bus->pcicore.dev) { | 402 | if (bus->pcicore.dev) { |
392 | ssb_printk(KERN_WARNING PFX | 403 | ssb_printk(KERN_WARNING PFX |
393 | "WARNING: Multiple PCI(E) cores found\n"); | 404 | "WARNING: Multiple PCI(E) cores found\n"); |