bcma_set_drvdata(dev, wldev); return 0; } static void wl_glue_bcma_remove(struct bcma_device *dev) { void *wldev = bcma_get_drvdata(dev); if (remove_cb) remove_cb(wldev); bcma_set_drvdata(dev, NULL); } static const struct bcma_device_id wl_glue_bcma_tbl[] = { BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_80211, BCMA_ANY_REV, BCMA_ANY_CLASS), BCMA_CORETABLE_END }; static struct bcma_driver wl_glue_bcma_driver = { .name = KBUILD_MODNAME, .id_table = wl_glue_bcma_tbl, .probe = wl_glue_bcma_probe, .remove = wl_glue_bcma_remove, }; #endif /* CONFIG_BCMA */ void wl_glue_set_attach_callback(wl_glue_attach_cb_t cb) { attach_cb = cb;
NULL }; static int n_adapters_found; MODULE_AUTHOR("Broadcom Corporation"); MODULE_DESCRIPTION("Broadcom 802.11n wireless LAN driver."); MODULE_SUPPORTED_DEVICE("Broadcom 802.11n WLAN cards"); MODULE_LICENSE("Dual BSD/GPL"); /* This needs to be adjusted when brcms_firmwares changes */ MODULE_FIRMWARE("brcm/bcm43xx-0.fw"); MODULE_FIRMWARE("brcm/bcm43xx_hdr-0.fw"); /* recognized BCMA Core IDs */ static struct bcma_device_id brcms_coreid_table[] = { BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_80211, 17, BCMA_ANY_CLASS), BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_80211, 23, BCMA_ANY_CLASS), BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_80211, 24, BCMA_ANY_CLASS), {}, }; MODULE_DEVICE_TABLE(bcma, brcms_coreid_table); #if defined(CONFIG_BRCMDBG) /* * Module parameter for setting the debug message level. Available * flags are specified by the BRCM_DL_* macros in * drivers/net/wireless/brcm80211/include/defs.h. */ module_param_named(debug, brcm_msg_level, uint, S_IRUGO | S_IWUSR); #endif
static const struct bcma_device_id b43_bcma_tbl[] = { BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_80211, 0x11, BCMA_ANY_CLASS), #ifdef CONFIG_B43_BCMA_EXTRA BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_80211, 0x17, BCMA_ANY_CLASS), BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_80211, 0x18, BCMA_ANY_CLASS), #endif BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_80211, 0x1D, BCMA_ANY_CLASS), BCMA_CORETABLE_END };
#include "bgmac.h" #include <linux/kernel.h> #include <linux/module.h> #include <linux/delay.h> #include <linux/etherdevice.h> #include <linux/mii.h> #include <linux/phy.h> #include <linux/phy_fixed.h> #include <linux/interrupt.h> #include <linux/dma-mapping.h> #include <linux/bcm47xx_nvram.h> static const struct bcma_device_id bgmac_bcma_tbl[] = { BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_4706_MAC_GBIT, BCMA_ANY_REV, BCMA_ANY_CLASS), BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_MAC_GBIT, BCMA_ANY_REV, BCMA_ANY_CLASS), {}, }; MODULE_DEVICE_TABLE(bcma, bgmac_bcma_tbl); static inline bool bgmac_is_bcm4707_family(struct bgmac *bgmac) { switch (bgmac->core->bus->chipinfo.id) { case BCMA_CHIP_ID_BCM4707: case BCMA_CHIP_ID_BCM47094: case BCMA_CHIP_ID_BCM53018: return true; default: return false; }
static int bcma_hcd_resume(struct bcma_device *dev) { bcma_hci_platform_power_gpio(dev, true); bcma_core_enable(dev, 0); return 0; } #else /* !CONFIG_PM */ #define bcma_hcd_suspend NULL #define bcma_hcd_resume NULL #endif /* CONFIG_PM */ static const struct bcma_device_id bcma_hcd_table[] = { BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_USB20_HOST, BCMA_ANY_REV, BCMA_ANY_CLASS), BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_NS_USB20, BCMA_ANY_REV, BCMA_ANY_CLASS), {}, }; MODULE_DEVICE_TABLE(bcma, bcma_hcd_table); static struct bcma_driver bcma_hcd_driver = { .name = KBUILD_MODNAME, .id_table = bcma_hcd_table, .probe = bcma_hcd_probe, .remove = bcma_hcd_remove, .shutdown = bcma_hcd_shutdown, .suspend = bcma_hcd_suspend, .resume = bcma_hcd_resume, };
} } return 0; } /************************************************** * BCMA **************************************************/ static struct spi_board_info bcm53xx_info = { .modalias = "bcm53xxspiflash", }; static const struct bcma_device_id bcm53xxspi_bcma_tbl[] = { BCMA_CORE(BCMA_MANUF_BCM, BCMA_CORE_NS_QSPI, BCMA_ANY_REV, BCMA_ANY_CLASS), {}, }; MODULE_DEVICE_TABLE(bcma, bcm53xxspi_bcma_tbl); static int bcm53xxspi_bcma_probe(struct bcma_device *core) { struct bcm53xxspi *b53spi; struct spi_master *master; int err; if (core->bus->drv_cc.core->id.rev != 42) { pr_err("SPI on SoC with unsupported ChipCommon rev\n"); return -ENOTSUPP; }