diff options
Diffstat (limited to 'drivers/bcma')
-rw-r--r-- | drivers/bcma/Kconfig | 2 | ||||
-rw-r--r-- | drivers/bcma/driver_pci_host.c | 1 | ||||
-rw-r--r-- | drivers/bcma/sprom.c | 7 |
3 files changed, 7 insertions, 3 deletions
diff --git a/drivers/bcma/Kconfig b/drivers/bcma/Kconfig index c1172dafdffa..fb7c80fb721e 100644 --- a/drivers/bcma/Kconfig +++ b/drivers/bcma/Kconfig | |||
@@ -29,7 +29,7 @@ config BCMA_HOST_PCI | |||
29 | 29 | ||
30 | config BCMA_DRIVER_PCI_HOSTMODE | 30 | config BCMA_DRIVER_PCI_HOSTMODE |
31 | bool "Driver for PCI core working in hostmode" | 31 | bool "Driver for PCI core working in hostmode" |
32 | depends on BCMA && MIPS | 32 | depends on BCMA && MIPS && BCMA_HOST_PCI |
33 | help | 33 | help |
34 | PCI core hostmode operation (external PCI bus). | 34 | PCI core hostmode operation (external PCI bus). |
35 | 35 | ||
diff --git a/drivers/bcma/driver_pci_host.c b/drivers/bcma/driver_pci_host.c index 4e20bcfa7ec5..d2097a11c3c7 100644 --- a/drivers/bcma/driver_pci_host.c +++ b/drivers/bcma/driver_pci_host.c | |||
@@ -10,6 +10,7 @@ | |||
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include "bcma_private.h" | 12 | #include "bcma_private.h" |
13 | #include <linux/pci.h> | ||
13 | #include <linux/export.h> | 14 | #include <linux/export.h> |
14 | #include <linux/bcma/bcma.h> | 15 | #include <linux/bcma/bcma.h> |
15 | #include <asm/paccess.h> | 16 | #include <asm/paccess.h> |
diff --git a/drivers/bcma/sprom.c b/drivers/bcma/sprom.c index cdcf75c0954f..3e2a6002aae6 100644 --- a/drivers/bcma/sprom.c +++ b/drivers/bcma/sprom.c | |||
@@ -404,16 +404,19 @@ int bcma_sprom_get(struct bcma_bus *bus) | |||
404 | return -EOPNOTSUPP; | 404 | return -EOPNOTSUPP; |
405 | 405 | ||
406 | if (!bcma_sprom_ext_available(bus)) { | 406 | if (!bcma_sprom_ext_available(bus)) { |
407 | bool sprom_onchip; | ||
408 | |||
407 | /* | 409 | /* |
408 | * External SPROM takes precedence so check | 410 | * External SPROM takes precedence so check |
409 | * on-chip OTP only when no external SPROM | 411 | * on-chip OTP only when no external SPROM |
410 | * is present. | 412 | * is present. |
411 | */ | 413 | */ |
412 | if (bcma_sprom_onchip_available(bus)) { | 414 | sprom_onchip = bcma_sprom_onchip_available(bus); |
415 | if (sprom_onchip) { | ||
413 | /* determine offset */ | 416 | /* determine offset */ |
414 | offset = bcma_sprom_onchip_offset(bus); | 417 | offset = bcma_sprom_onchip_offset(bus); |
415 | } | 418 | } |
416 | if (!offset) { | 419 | if (!offset || !sprom_onchip) { |
417 | /* | 420 | /* |
418 | * Maybe there is no SPROM on the device? | 421 | * Maybe there is no SPROM on the device? |
419 | * Now we ask the arch code if there is some sprom | 422 | * Now we ask the arch code if there is some sprom |