summaryrefslogtreecommitdiffstats
path: root/drivers/bcma/main.c
Commit message (Collapse)AuthorAgeFilesLines
* driver core: make struct bus_type.uevent() take a const *Greg Kroah-Hartman2023-01-271-3/+3
| | | | | | | | | | | | The uevent() callback in struct bus_type should not be modifying the device that is passed into it, so mark it as a const * and propagate the function signature changes out into all relevant subsystems that use this callback. Acked-by: Rafael J. Wysocki <rafael@kernel.org> Acked-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20230111113018.459199-16-gregkh@linuxfoundation.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* bcma: Fail probe if GPIO subdriver failsLinus Walleij2022-11-041-1/+3
| | | | | | | | | | | | | We currently register the BCMA core even if the GPIO portions fail. There is no reason for this: the GPIO should register just fine, if it fails the BCMA driver should fail. We already gracefully handle the case where the GPIO driver is not compiled in. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://lore.kernel.org/r/20221028093000.239020-1-linus.walleij@linaro.org
* bcma: cleanup commentsTom Rix2022-02-211-2/+2
| | | | | | | | | | | | | | | | | | | Remove the second 'info'. Replacements 'adventages' with 'advantages' 'strenth' with 'strength' 'atleast' with 'at least' 'thr'u'' with 'through' 'capabilty' with 'capability' 'controll' with 'control' 'ourself' with 'ourselves' 'noone' with 'no one' 'cores' to 'core's' and 'core' Signed-off-by: Tom Rix <trix@redhat.com> Reviewed-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://lore.kernel.org/r/20220213213121.2806376-1-trix@redhat.com
* bcma: drop unneeded initialization valueSohaib Mohamed2021-10-051-1/+1
| | | | | | | | | Do not initialise statics to 0 ERROR found by checkpatch.pl Signed-off-by: Sohaib Mohamed <sohaib.amhmd@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> Link: https://lore.kernel.org/r/20210930194920.15847-1-sohaib.amhmd@gmail.com
* Merge tag 'driver-core-5.15-rc1' of ↵Linus Torvalds2021-09-011-4/+2
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core Pull driver core updates from Greg KH: "Here is the big set of driver core patches for 5.15-rc1. These do change a number of different things across different subsystems, and because of that, there were 2 stable tags created that might have already come into your tree from different pulls that did the following - changed the bus remove callback to return void - sysfs iomem_get_mapping rework Other than those two things, there's only a few small things in here: - kernfs performance improvements for huge numbers of sysfs users at once - tiny api cleanups - other minor changes All of these have been in linux-next for a while with no reported problems, other than the before-mentioned merge issue" * tag 'driver-core-5.15-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (33 commits) MAINTAINERS: Add dri-devel for component.[hc] driver core: platform: Remove platform_device_add_properties() ARM: tegra: paz00: Handle device properties with software node API bitmap: extend comment to bitmap_print_bitmask/list_to_buf drivers/base/node.c: use bin_attribute to break the size limitation of cpumap ABI topology: use bin_attribute to break the size limitation of cpumap ABI lib: test_bitmap: add bitmap_print_bitmask/list_to_buf test cases cpumask: introduce cpumap_print_list/bitmask_to_buf to support large bitmask and list sysfs: Rename struct bin_attribute member to f_mapping sysfs: Invoke iomem_get_mapping() from the sysfs open callback debugfs: Return error during {full/open}_proxy_open() on rmmod zorro: Drop useless (and hardly used) .driver member in struct zorro_dev zorro: Simplify remove callback sh: superhyway: Simplify check in remove callback nubus: Simplify check in remove callback nubus: Make struct nubus_driver::remove return void kernfs: dont call d_splice_alias() under kernfs node lock kernfs: use i_lock to protect concurrent inode updates kernfs: switch kernfs to use an rwsem kernfs: use VFS negative dentry caching ...
| * bus: Make remove callback return voidUwe Kleine-König2021-07-211-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The driver core ignores the return value of this callback because there is only little it can do when a device disappears. This is the final bit of a long lasting cleanup quest where several buses were converted to also return void from their remove callback. Additionally some resource leaks were fixed that were caused by drivers returning an error code in the expectation that the driver won't go away. With struct bus_type::remove returning void it's prevented that newly implemented buses return an ignored error code and so don't anticipate wrong expectations for driver authors. Reviewed-by: Tom Rix <trix@redhat.com> (For fpga) Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Cornelia Huck <cohuck@redhat.com> (For drivers/s390 and drivers/vfio) Acked-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk> (For ARM, Amba and related parts) Acked-by: Mark Brown <broonie@kernel.org> Acked-by: Chen-Yu Tsai <wens@csie.org> (for sunxi-rsb) Acked-by: Pali Rohár <pali@kernel.org> Acked-by: Mauro Carvalho Chehab <mchehab@kernel.org> (for media) Acked-by: Hans de Goede <hdegoede@redhat.com> (For drivers/platform) Acked-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Acked-By: Vinod Koul <vkoul@kernel.org> Acked-by: Juergen Gross <jgross@suse.com> (For xen) Acked-by: Lee Jones <lee.jones@linaro.org> (For mfd) Acked-by: Johannes Thumshirn <jth@kernel.org> (For mcb) Acked-by: Johan Hovold <johan@kernel.org> Acked-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> (For slimbus) Acked-by: Kirti Wankhede <kwankhede@nvidia.com> (For vfio) Acked-by: Maximilian Luz <luzmaximilian@gmail.com> Acked-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> (For ulpi and typec) Acked-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com> (For ipack) Acked-by: Geoff Levand <geoff@infradead.org> (For ps3) Acked-by: Yehezkel Bernat <YehezkelShB@gmail.com> (For thunderbolt) Acked-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> (For intel_th) Acked-by: Dominik Brodowski <linux@dominikbrodowski.net> (For pcmcia) Acked-by: Rafael J. Wysocki <rafael@kernel.org> (For ACPI) Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> (rpmsg and apr) Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> (For intel-ish-hid) Acked-by: Dan Williams <dan.j.williams@intel.com> (For CXL, DAX, and NVDIMM) Acked-by: William Breathitt Gray <vilhelm.gray@gmail.com> (For isa) Acked-by: Stefan Richter <stefanr@s5r6.in-berlin.de> (For firewire) Acked-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> (For hid) Acked-by: Thorsten Scherer <t.scherer@eckelmann.de> (For siox) Acked-by: Sven Van Asbroeck <TheSven73@gmail.com> (For anybuss) Acked-by: Ulf Hansson <ulf.hansson@linaro.org> (For MMC) Acked-by: Wolfram Sang <wsa@kernel.org> # for I2C Acked-by: Sudeep Holla <sudeep.holla@arm.com> Acked-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Acked-by: Finn Thain <fthain@linux-m68k.org> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Link: https://lore.kernel.org/r/20210713193522.1770306-6-u.kleine-koenig@pengutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | bcma: Fix memory leak for internally-handled coresZenghui Yu2021-08-291-3/+3
|/ | | | | | | | | | | | | | | | | kmemleak reported that dev_name() of internally-handled cores were leaked on driver unbinding. Let's use device_initialize() to take refcounts for them and put_device() to properly free the related stuff. While looking at it, there's another potential issue for those which should be *registered* into driver core. If device_register() failed, we put device once and freed bcma_device structures. In bcma_unregister_cores(), they're treated as unregistered and we hit both UAF and double-free. That smells not good and has also been fixed now. Fixes: ab54bc8460b5 ("bcma: fill core details for every device") Signed-off-by: Zenghui Yu <yuzenghui@huawei.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> Link: https://lore.kernel.org/r/20210727025232.663-2-yuzenghui@huawei.com
* bcma: keep a direct pointer to the struct deviceRafał Miłecki2019-01-101-35/+10
| | | | | | | | | | | Accessing struct device is pretty useful/common so having a direct pointer: 1) Simplifies some code 2) Makes bcma_bus_get_host_dev() unneeded 3) Allows further improvements like using dev_* printing helpers Signed-off-by: Rafał Miłecki <rafal@milecki.pl> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* drivers: remove force dma flag from busesChristoph Hellwig2018-05-031-1/+1
| | | | | | | | | | | | | | With each bus implementing its own DMA configuration callback, there is no need for bus to explicitly set the force_dma flag. Modify the of_dma_configure function to accept an input parameter which specifies if implicit DMA configuration is required when it is not described by the firmware. Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com> Acked-by: Bjorn Helgaas <bhelgaas@google.com> # PCI parts Reviewed-by: Rob Herring <robh@kernel.org> [hch: tweaked the changelog a bit] Signed-off-by: Christoph Hellwig <hch@lst.de>
* bcma: fill core OF info independently of bus typeRafał Miłecki2017-03-201-2/+2
| | | | | | | | | PCI devices can be described in DT as well so we should always execute relevant code. This will make bcma e.g. set of_node for cores described in DT. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: use helper function to set core dev's parentRafał Miłecki2017-03-201-2/+1
| | | | | | | A tiny code deduplication thanks to the bcma_bus_get_host_dev. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: drop unneeded check for CONFIG_OF_IRQRafał Miłecki2017-03-201-3/+0
| | | | | | | | | | | | | We already have the same check in bcma_of_get_irq which really calls symbols available with CONFIG_OF_IRQ only. It appears this duplicated check was accidentally added in commit c58d900cc96a ("bcma: fix building without OF_IRQ"). The rest of code in bcma_of_fill_device should work fine without CONFIG_OF_IRQ. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> Cc: Arnd Bergmann <arnd@arndb.de> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: make OF code more generic (not platform_device specific)Rafał Miłecki2017-01-311-10/+11
| | | | | | | | | OF allows not only specifying platform devices but also describing devices on standard buses like PCI or USB. This change will allow reading info from DT for bcma buses hosted on PCI cards. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: use (get|put)_device when probing/removing device driverRafał Miłecki2017-01-311-0/+4
| | | | | | | | This allows tracking device state and e.g. makes devm work as expected. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> Cc: Stable <stable@vger.kernel.org> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: use of_dma_configure() to set initial dma maskArnd Bergmann2016-09-091-2/+4
| | | | | | | | | | | | | | | | While fixing another bug, I noticed that bcma manually sets up a dma_mask pointer for its child devices. We have a generic helper for that now, which should be able to cope better with any variations that might be needed to deal with cache coherency, unusual DMA address offsets, iommus, or limited DMA masks, none of which are currently handled here. This changes the core to use the of_dma_configure(), like we do for platform devices that are probed directly from DT. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: fix building without OF_IRQArnd Bergmann2016-03-231-13/+4
| | | | | | | | | | | | | | | | | | | | | | The bcma driver core can be built with or without DT support, but it fails to build when CONFIG_OF=y and CONFIG_OF_IRQ=n, which can happen on platforms that do not support IRQ domains. ERROR: "irq_create_of_mapping" [drivers/bcma/bcma.ko] undefined! ERROR: "of_irq_parse_raw" [drivers/bcma/bcma.ko] undefined! ERROR: "of_irq_parse_one" [drivers/bcma/bcma.ko] undefined! This adds another compile-time check for OF_IRQ, but also gets rid of now unneeded #ifdef checks: Using the simpler IS_ENABLED() check for OF_IRQ also covers the case of not having CONFIG_OF enabled. The check for CONFIG_OF_ADDRESS was added to allow building on architectures without OF_ADDRESS, but that has been addressed already in b1d06b60e90c ("of: Provide static inline function for of_translate_address if needed"). Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: move parallel flash support to separated fileRafał Miłecki2016-03-071-1/+1
| | | | | | | | | | | This follows the way of handling other flashes and cleans code a bit. As next task we will want to move flash code to ChipCommon driver as: 1) Flash controllers are accesible using ChipCommon registers 2) This code isn't MIPS specific This change prepares bcma for that. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: use module_init for the main part of bus initializationRafał Miłecki2015-12-311-2/+27
| | | | | | | | | | | | | | | So far we were using fs_initcall. It was (and still is) needed because struct bus_type has to be registered early. However main bus initialization has to happen later as it requires SPROM which depends on NVRAM which depends on mtd. Solve it by using fs_initcall only for bus_register call and module_init for the rest. It affects bcma only when built-in obviously. This was tested with BCM4706 and BCM5357C0 (BCM47XX), BCM4708A0 (ARCH_BCM_5301X) and BCM43225 (PCIe card with bcma as module). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: add support for population subnodes also when build as moduleHauke Mehrtens2015-09-291-7/+2
| | | | | | | | | | | | of_default_bus_match_table was not exported earlier, so it could only be accessed by code compiled into the kernel. A new function of_platform_default_populate() was added which uses of_default_bus_match_table and this function is also exported. This way it is possible to create a bus with the content of of_default_bus_match_table and we can remove the hacks from bcma. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: fix access to host_pdev for PCIe devicesHauke Mehrtens2015-08-101-3/+27
| | | | | | | | | | | | | | | | | | | | | | | bus->host_pdev is part of a union so bus->host_pdev != NULL is probably also true for PCIe devices, because there it accesses bus->host_pci. If we access the dev member at the offset defined in struct platform_device in struct pci_dev instead we probably get something else. This patch adds a new function which returns the host dev struct and NULL if we do not have a host dev. When this gets registered on MIPS brcm47xx we do not have a host dev in some situations. This function could also be used in other places. This problem was introduced in this commit: commit cae761b5a6bdc597ba476a040fdcd5b4bc559b85 Author: Rafa? Mi?ecki <zajec5@gmail.com> Date: Sun Jun 28 17:17:13 2015 +0200 bcma: populate bus DT subnodes as platform_device-s Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: fix build error when build as moduleHauke Mehrtens2015-07-261-1/+5
| | | | | | | | | | | | | | | | | | Currently of_default_bus_match_table is not exported so we can only use this feature when bcma is build into the kernel. This patch removes support for child buses when bcma is build as a module as a temporary fix for a build problem introduces in this commit: commit cae761b5a6bdc597ba476a040fdcd5b4bc559b85 Author: Rafał Miłecki <zajec5@gmail.com> Date: Sun Jun 28 17:17:13 2015 +0200 bcma: populate bus DT subnodes as platform_device-s Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Fixes: cae761b5a6bd ("bcma: populate bus DT subnodes as platform_device-s") Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: populate bus DT subnodes as platform_device-sRafał Miłecki2015-07-211-0/+8
| | | | | | | | | Our bus should allow defining children nodes as we may want to specify devices attached to the bus. This is required e.g. to specify NAND or ChipCommon cores and use bus's address and IRQ mappings. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: enable support for PCIe Gen 2 host devicesRafał Miłecki2015-03-021-1/+1
| | | | | Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: add early_init function for PCIe core and move some fix into itRafał Miłecki2015-01-291-0/+7
| | | | | | | | There are some PCIe core fixes that need to be applied before accessing SPROM, otherwise reading it may fail. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: simplify freeing cores (internal devices structs)Rafał Miłecki2015-01-291-11/+9
| | | | | Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: use standard bus scanning during early registerRafał Miłecki2015-01-231-24/+9
| | | | | | | | | Starting with kernel 3.19-rc1 early registration of bcma on MIPS is done a bit later, with memory allocator available. This allows us to simplify code by using standard bus scanning method. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* bcma: clean bus initialization codeRafał Miłecki2015-01-231-4/+12
| | | | | | | | | | This moves main bus init code to the main.c and renames old function to make its purpose clear. Thanks to this change we'll also be able to separate scanning from registration (and support PCIe Gen 2 devices) in the future. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* Merge commit '4e6ce4dc7ce71d0886908d55129d5d6482a27ff9' of ↵John W. Linville2014-11-191-1/+1
|\ | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless
| * bcma: fix build when CONFIG_OF_ADDRESS is not setHauke Mehrtens2014-10-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 2101e533f41a ("bcma: register bcma as device tree driver") introduces a hard dependency on OF_ADDRESS into the bcma driver. OF_ADDRESS is specifically disabled for the sparc architecture. This results in the following error when building sparc64:allmodconfig. drivers/bcma/main.c: In function 'bcma_of_find_child_device': drivers/bcma/main.c:150:3: error: implicit declaration of function 'of_translate_address' Fixes: 2101e533f41a ("bcma: register bcma as device tree driver") Reported-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Reviewed-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | bcma: get IRQ numbers from dtHauke Mehrtens2014-11-111-1/+51
| | | | | | | | | | | | | | | | | | | | It is not possible to auto detect the irq numbers used by the cores on an arm SoC. If bcma was registered with device tree it will search for some device tree nodes with the irq number and add it to the core configuration. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | bcma: make it possible to specify a IRQ num in bcma_core_irq()Hauke Mehrtens2014-11-111-0/+22
| | | | | | | | | | | | | | | | | | This moves bcma_core_irq() to main.c and add a extra parameter with a number so that we can return different irq number for devices with more than one. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | bcma: fill core details for every deviceRafał Miłecki2014-10-271-3/+6
|/ | | | | | | | | | We were setting things like dma_dev, IRQ, etc. during core registration only. We need such info for cores handled internally (e.g. ChipCommon) as well. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: register bcma as device tree driverHauke Mehrtens2014-09-301-1/+51
| | | | | | | | | | This driver is used by the bcm53xx ARM SoC code. Now it is possible to give the address of the chipcommon core in device tree and bcma will search for all the other cores. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: add support for chipcommon B coreHauke Mehrtens2014-09-091-0/+10
| | | | | | | | | This core is used on BCM4708 to configure the PCIe and USB3 PHYs and it contains the addresses to the Device Management unit. This will be used by the PCIe driver first. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: register NAND and QSPI cores earlyRafał Miłecki2014-09-091-0/+21
| | | | | | | | | | On Northstar (ARM arch) we will use MTD subsystem to access NVRAM and SPROM. To get access to flash device we need to register these cores first. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: move code for core registration into separate functionRafał Miłecki2014-09-091-31/+36
| | | | | | | | | | This cleans code a bit and will us to register cores in other places as well. The only difference with this patch is using "core_index" for setting device name. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: move bus struct setup into early part of host specific codeRafał Miłecki2014-09-091-2/+0
| | | | | | | | | This change is important for SoC host. In future we will want to know chip ID (needed for early MIPS boot) before doing cores scanning. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: add driver for PCIe Gen 2 coreRafał Miłecki2014-07-071-0/+8
| | | | | | | | New Broadcom PCIe devices (802.11ac ones?) use Gen2 and have to be initialized differently. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: export bcma_find_core_unit()Hauke Mehrtens2014-01-041-12/+1
| | | | | | | | | | This function is used to get a specific core when there is more than one core of that specific type. This is used in bgmac to reset all GMAC cores. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Acked-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* bcma: add missing put_device callLevente Kurusa2013-12-191-0/+1
| | | | | | | This is required so that we give up the last reference to the device. Signed-off-by: Levente Kurusa <levex@linux.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: convert bus code to use dev_groupsGreg Kroah-Hartman2013-10-161-7/+16
| | | | | | | | | The dev_attrs field of struct bus_type is going away soon, dev_groups should be used instead. This converts the bcma bus code to use the correct field. Acked-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* bcma: return correct error code when bus scan failedHauke Mehrtens2013-07-221-1/+1
| | | | | | | It is better to return the actual error code than just -1. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: add support for BCM43142Rafał Miłecki2013-06-271-0/+19
| | | | | Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* bcma: ignore extra GMAC cores on BCM4706Rafał Miłecki2013-03-061-0/+5
| | | | | Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller2013-02-081-0/+7
|\ | | | | | | | | | | | | Synchronize with 'net' in order to sort out some l2tp, wireless, and ipv6 GRE fixes that will be built on top of in 'net-next'. Signed-off-by: David S. Miller <davem@davemloft.net>
| * Merge branch 'master' of ↵John W. Linville2013-02-061-0/+7
| |\ | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless into for-davem
| | * bcma: unregister gpios before unloading bcmaHauke Mehrtens2013-02-041-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | This patch unregisters the gpio chip before bcma gets unloaded. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Reported-by: Piotr Haber <phaber@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | Merge branch 'master' of ↵John W. Linville2013-02-081-0/+8
|\ \ \ | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next into for-davem
| * | | bcma: register platform device for parallel flashRafał Miłecki2013-01-301-0/+8
| | | | | | | | | | | | | | | | Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | | Merge branch 'master' of ↵John W. Linville2013-01-281-2/+2
|\| | | | |/ / |/| | | | | git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next into for-davem