bcma: fix build error on MIPS; implicit pcibios_enable_device
authorPaul Gortmaker <paul.gortmaker@windriver.com>
Mon, 26 Mar 2012 00:02:55 +0000 (20:02 -0400)
committerVarun Wadekar <vwadekar@nvidia.com>
Wed, 18 Apr 2012 14:31:39 +0000 (19:31 +0530)
commit3fc4acfa46d4d3a76e979c6ba87941cf98ac914f
tree17e1796282960ea5c9f0091c7351edd2a7b70a26
parentc006e1ddafe6375792f3bf95a671767a730d6839
bcma: fix build error on MIPS; implicit pcibios_enable_device

The following is seen during allmodconfig builds for MIPS:

drivers/bcma/driver_pci_host.c:518:2: error: implicit declaration
of function 'pcibios_enable_device' [-Werror=implicit-function-declaration]
cc1: some warnings being treated as errors
make[3]: *** [drivers/bcma/driver_pci_host.o] Error 1

Most likey introduced by commit 49dc9577155576b10ff79f0c1486c816b01f58bf

    "bcma: add PCIe host controller"

Add the header instead of implicitly assuming it will be present.
Sounds like a good idea, but that alone doesn't fix anything.

The real problem is that the Kconfig has settings related to whether
PCI is possible, i.e.

  config BCMA_HOST_PCI_POSSIBLE
        bool
        depends on BCMA && PCI = y
        default y

  config BCMA_HOST_PCI
        bool "Support for BCMA on PCI-host bus"
        depends on BCMA_HOST_PCI_POSSIBLE

...but what is missing is that BCMA_DRIVER_PCI_HOSTMODE doesn't
have any dependencies on the above.  Add one.

CC: Hauke Mehrtens <hauke@hauke-m.de>
CC: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Acked-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/bcma/Kconfig
drivers/bcma/driver_pci_host.c