summaryrefslogtreecommitdiffstats
path: root/drivers/bcma/driver_pci_host.c
Commit message (Collapse)AuthorAgeFilesLines
* Drivers: bcma: remove __dev* attributes.Greg Kroah-Hartman2013-01-041-7/+6Star
| | | | | | | | | | | | | | | CONFIG_HOTPLUG is going away as an option. As a result, the __dev* markings need to be removed. This change removes the use of __devinit, __devexit_p, and __devexit from these drivers. Based on patches originally written by Bill Pemberton, but redone by me in order to handle some of the coding style issues better, by hand. Cc: Bill Pemberton <wfp5p@virginia.edu> Cc: "Rafał Miłecki" <zajec5@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* bcma: handle return value of pci_assign_resourceHauke Mehrtens2012-11-301-3/+7
| | | | | | | | | | | | | | This fixes the following warning: CC drivers/bcma/driver_pci_host.o drivers/bcma/driver_pci_host.c: In function 'bcma_core_pci_fixup_addresses': drivers/bcma/driver_pci_host.c:555:23: error: ignoring return value of 'pci_assign_resource', declared with attribute warn_unused_result [-Werror=unused-result] Reported-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: do not initialize deactivated PCIe coresHauke Mehrtens2012-10-191-5/+5
| | | | | | | | | | Before it was tried to initialize the deactivated PCIe core in client mode, but this causes the SoC to hang. Just do not initialize it at all and ignore the core it is not working and nothing is connected to it when the specific bit is set in the boardflags. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: add an extra pcie core structHauke Mehrtens2012-10-191-0/+4
| | | | | | | | | | The BCM4706 has two PCIe host controller on the bcma bus. For PCIe client mode it is assumed that there is only one PCIe controller so the PCIe driver, like b43 and brcmsmac are accessing the first PCIe controller when they want to issue a operation on the host controller. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: change delays to follow timers-howto guideRafał Miłecki2012-09-281-4/+4
| | | | | | Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Cc: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: use custom printing functionsRafał Miłecki2012-07-091-4/+6
| | | | | | | | | Having bus number printed makes it much easier to anaylze logs on systems with more buses. For example Netgear WNDR4500 has 3 AMBA buses in total, which makes standard log really messy. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: add constants for chip idsHauke Mehrtens2012-07-091-3/+5
| | | | | | | | | The chip IDs are used all over bcma and no constants where defined. This patch adds the constants and makes bcma use them. Acked-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: reads/writes are always 4 bytes, so always map 4 bytesNathan Hintz2012-05-161-3/+3
| | | | | | | Modify ioremap_nocache calls to reflect the number of bytes read/written. Signed-off-by: Nathan Hintz <nlhintz@hotmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: Account for variable PCI memory base/sizeNathan Hintz2012-05-161-2/+2
| | | | | | | | | PCI Memory Resource start address and size are variable, dependent on the H/W configuration. Modify the computation of io_map_base to use the computed values. Signed-off-by: Nathan Hintz <nlhintz@hotmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: fix build error on MIPS; implicit pcibios_enable_devicePaul Gortmaker2012-04-101-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* bcma: add PCIe host controllerHauke Mehrtens2012-02-061-1/+575
| | | | | | | | | | Some SoCs have a PCIe host controller to make it possible to attach some other devices to it, like an other Wifi card. This code was tested with an Netgear WNDR3400 (bcm4716 based), but should work with all bcma based SoCs. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: make some functions __devinitHauke Mehrtens2012-02-061-1/+1
| | | | | | | | | bcma_core_pci_hostmode_init() has to be in __devinit as it will call a function in that section and so all functions calling it also have to be in __devinit. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: detect PCI core working in hostmodeRafał Miłecki2011-07-071-0/+14
We must not init it like clientmode one, it would break device (tested by Hauke on BCM4718). Add stub hostmode driver for now. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>