]> git.karo-electronics.de Git - linux-beck.git/commitdiff
brcmfmac: Add RSDB support.
authorHante Meuleman <meuleman@broadcom.com>
Thu, 29 Oct 2015 19:33:16 +0000 (20:33 +0100)
committerKalle Valo <kvalo@codeaurora.org>
Thu, 26 Nov 2015 11:55:09 +0000 (13:55 +0200)
Broadcom devices with a single 802.11 core can work on two band
concurrently using VSDB feature, ie. Virtual Simultaneous Dual-Band.
For devices that are fitted with two 802.11 cores and RF paths the
driver should support a firmware feature called RSDB, which stands
for Real Simultaneous Dual-Band. RSDB works almost autonomously in
firmware except for AP config. When the device supports RSDB then
the interface should not be brought down when configuring it,
otherwise the link (if configured) on the other interface will be
lost.

Reviewed-by: Arend Van Spriel <arend@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Hante Meuleman <meuleman@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
[kvalo@codeaurora.org: changed the commit log based on discussion]
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c
drivers/net/wireless/broadcom/brcm80211/brcmfmac/feature.c
drivers/net/wireless/broadcom/brcm80211/brcmfmac/feature.h

index deb5f78dcacc0d9ef188360d300a7b4f1bcfba19..8a3c9fa171ee316481545a55d2b0d3310cf59ada 100644 (file)
@@ -4183,7 +4183,9 @@ brcmf_cfg80211_start_ap(struct wiphy *wiphy, struct net_device *ndev,
                        }
                }
 
-               if (dev_role == NL80211_IFTYPE_AP) {
+               if ((dev_role == NL80211_IFTYPE_AP) &&
+                   ((ifp->ifidx == 0) ||
+                    !brcmf_feat_is_enabled(ifp, BRCMF_FEAT_RSDB))) {
                        err = brcmf_fil_cmd_int_set(ifp, BRCMF_C_DOWN, 1);
                        if (err < 0) {
                                brcmf_err("BRCMF_C_DOWN error %d\n", err);
index 44bb3063669038fbfe0fee1b96a0cde929fae1e2..ba5249403036600b699dfbb47825d9c707a37067 100644 (file)
@@ -137,6 +137,7 @@ void brcmf_feat_attach(struct brcmf_pub *drvr)
        if (drvr->bus_if->chip != BRCM_CC_43362_CHIP_ID)
                brcmf_feat_iovar_int_set(ifp, BRCMF_FEAT_MBSS, "mbss", 0);
        brcmf_feat_iovar_int_get(ifp, BRCMF_FEAT_P2P, "p2p");
+       brcmf_feat_iovar_int_get(ifp, BRCMF_FEAT_RSDB, "rsdb_mode");
 
        if (brcmf_feature_disable) {
                brcmf_dbg(INFO, "Features: 0x%02x, disable: 0x%02x\n",
index 6b381f799f228b5cb2e6b0f62c2556b7747a7e3d..538175882c8a0787e402fbfcc25b539f1745d949 100644 (file)
  * PNO: preferred network offload.
  * WOWL: Wake-On-WLAN.
  * P2P: peer-to-peer
+ * RSDB: Real Simultaneous Dual Band
  */
 #define BRCMF_FEAT_LIST \
        BRCMF_FEAT_DEF(MBSS) \
        BRCMF_FEAT_DEF(MCHAN) \
        BRCMF_FEAT_DEF(PNO) \
        BRCMF_FEAT_DEF(WOWL) \
-       BRCMF_FEAT_DEF(P2P)
+       BRCMF_FEAT_DEF(P2P) \
+       BRCMF_FEAT_DEF(RSDB)
+
 /*
  * Quirks:
  *