Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion drivers/net/wireless/broadcom/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ obj-$(CONFIG_B43) += b43/
obj-$(CONFIG_B43LEGACY) += b43legacy/

obj-$(CONFIG_BRCMFMAC) += brcm80211/
obj-$(CONFIG_BRCMSMAC) += brcm80211/
#obj-$(CONFIG_BRCMSMAC) += brcm80211/
29 changes: 26 additions & 3 deletions drivers/net/wireless/broadcom/brcm80211/Kconfig
Original file line number Diff line number Diff line change
@@ -1,17 +1,20 @@
# SPDX-License-Identifier: GPL-2.0-only
config BRCMUTIL
tristate
depends on m

config BRCMSMAC
depends on n
tristate "Broadcom IEEE802.11n PCIe SoftMAC WLAN driver"
depends on m
depends on MAC80211
depends on BCMA_POSSIBLE
select BCMA
depends on BCMA
select NEW_LEDS if BCMA_DRIVER_GPIO
select LEDS_CLASS if BCMA_DRIVER_GPIO
select BRCMUTIL
select FW_LOADER
select CORDIC
select BPAUTO_CORDIC
help
This module adds support for PCIe wireless adapters based on Broadcom
IEEE802.11n SoftMAC chipsets. It also has WLAN led support, which will
Expand All @@ -34,6 +37,26 @@ config BRCM_TRACING
config BRCMDBG
bool "Broadcom driver debug functions"
depends on BRCMSMAC || BRCMFMAC
select WANT_DEV_COREDUMP if BRCMFMAC
select BPAUTO_WANT_DEV_COREDUMP
help
Selecting this enables additional code for debug purposes.

config BRCMFMAC_PCIE_BARWIN_SZ
bool "Custom PCIE BAR window size support for FullMAC driver"
depends on BRCMFMAC
depends on PCI
default n
help
If you say Y here, the FMAC driver will use custom PCIE BAR
window size. Say Y to allow developers to use custom PCIE
BAR window size when HOST PCIE IP can support less then 4MB
BAR window.

config BRCMFMAC_BT_SHARED_SDIO
bool "FMAC shares SDIO bus to Bluetooth"
depends on BRCMFMAC
depends on BRCMFMAC_SDIO
default n
help
Selecting this to enables sharing the SDIO bus interface between
Cypress BT and WiFi host drivers.
2 changes: 1 addition & 1 deletion drivers/net/wireless/broadcom/brcm80211/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ subdir-ccflags-$(CONFIG_BRCMDBG) += -DDEBUG

obj-$(CONFIG_BRCMUTIL) += brcmutil/
obj-$(CONFIG_BRCMFMAC) += brcmfmac/
obj-$(CONFIG_BRCMSMAC) += brcmsmac/
#obj-$(CONFIG_BRCMSMAC) += brcmsmac/
14 changes: 11 additions & 3 deletions drivers/net/wireless/broadcom/brcm80211/brcmfmac/Kconfig
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
config BRCMFMAC
tristate "Broadcom FullMAC WLAN driver"
depends on m
depends on CFG80211
select BRCMUTIL
help
Expand All @@ -19,7 +20,7 @@ config BRCMFMAC_SDIO
depends on (MMC = y || MMC = BRCMFMAC)
depends on BRCMFMAC
select BRCMFMAC_PROTO_BCDC
select FW_LOADER
depends on FW_LOADER
default y
help
This option enables the SDIO bus interface support for Broadcom
Expand All @@ -31,7 +32,7 @@ config BRCMFMAC_USB
depends on (USB = y || USB = BRCMFMAC)
depends on BRCMFMAC
select BRCMFMAC_PROTO_BCDC
select FW_LOADER
depends on FW_LOADER
help
This option enables the USB bus interface support for Broadcom
IEEE802.11n embedded FullMAC WLAN driver. Say Y if you want to
Expand All @@ -42,9 +43,16 @@ config BRCMFMAC_PCIE
depends on BRCMFMAC
depends on PCI
select BRCMFMAC_PROTO_MSGBUF
select FW_LOADER
depends on FW_LOADER
help
This option enables the PCIE bus interface support for Broadcom
IEEE802.11ac embedded FullMAC WLAN driver. Say Y if you want to
use the driver for an PCIE wireless card.

config BRCMFMAC_BT_SHARED_SDIO
bool "FMAC shares SDIO bus to Bluetooth"
depends on BRCMFMAC_SDIO
default n
help
This option enables the feautre of sharing the SDIO bus interface
between Cypress BT and WiFi host drivers.
6 changes: 4 additions & 2 deletions drivers/net/wireless/broadcom/brcm80211/brcmfmac/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
#

ccflags-y += \
-I $(srctree)/$(src) \
-I $(srctree)/$(src)/../include
-I$(src) \
-I$(src)/../include

obj-$(CONFIG_BRCMFMAC) += brcmfmac.o
brcmfmac-objs += \
Expand Down Expand Up @@ -46,3 +46,5 @@ brcmfmac-$(CONFIG_OF) += \
of.o
brcmfmac-$(CONFIG_DMI) += \
dmi.o
brcmfmac-${CONFIG_BRCMFMAC_BT_SHARED_SDIO} += \
bt_shared_sdio.o
7 changes: 4 additions & 3 deletions drivers/net/wireless/broadcom/brcm80211/brcmfmac/bcdc.c
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,8 @@ struct brcmf_proto_bcdc_header {
* plus any space that might be needed
* for bus alignment padding.
*/
#define ROUND_UP_MARGIN 2048

struct brcmf_bcdc {
u16 reqid;
u8 bus_header[BUS_HEADER_LEN];
Expand Down Expand Up @@ -368,8 +370,7 @@ brcmf_proto_bcdc_txcomplete(struct device *dev, struct sk_buff *txp,

/* await txstatus signal for firmware if active */
if (brcmf_fws_fc_active(bcdc->fws)) {
if (!success)
brcmf_fws_bustxfail(bcdc->fws, txp);
brcmf_fws_bustxcomplete(bcdc->fws, txp, success);
} else {
if (brcmf_proto_bcdc_hdrpull(bus_if->drvr, false, txp, &ifp))
brcmu_pkt_buf_free_skb(txp);
Expand Down Expand Up @@ -471,7 +472,7 @@ int brcmf_proto_bcdc_attach(struct brcmf_pub *drvr)

drvr->hdrlen += BCDC_HEADER_LEN + BRCMF_PROT_FW_SIGNAL_MAX_TXBYTES;
drvr->bus_if->maxctl = BRCMF_DCMD_MAXLEN +
sizeof(struct brcmf_proto_bcdc_dcmd);
sizeof(struct brcmf_proto_bcdc_dcmd) + ROUND_UP_MARGIN;
return 0;

fail:
Expand Down
Loading