aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/brcm80211/brcmfmac/dhd_common.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/brcm80211/brcmfmac/dhd_common.c')
-rw-r--r--drivers/net/wireless/brcm80211/brcmfmac/dhd_common.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/drivers/net/wireless/brcm80211/brcmfmac/dhd_common.c b/drivers/net/wireless/brcm80211/brcmfmac/dhd_common.c
index 6a8983a1fb9c..ed3e32ce8c23 100644
--- a/drivers/net/wireless/brcm80211/brcmfmac/dhd_common.c
+++ b/drivers/net/wireless/brcm80211/brcmfmac/dhd_common.c
@@ -32,6 +32,9 @@
32#define BRCMF_DEFAULT_SCAN_UNASSOC_TIME 40 32#define BRCMF_DEFAULT_SCAN_UNASSOC_TIME 40
33#define BRCMF_DEFAULT_PACKET_FILTER "100 0 0 0 0x01 0x00" 33#define BRCMF_DEFAULT_PACKET_FILTER "100 0 0 0 0x01 0x00"
34 34
35/* boost value for RSSI_DELTA in preferred join selection */
36#define BRCMF_JOIN_PREF_RSSI_BOOST 8
37
35 38
36bool brcmf_c_prec_enq(struct device *dev, struct pktq *q, 39bool brcmf_c_prec_enq(struct device *dev, struct pktq *q,
37 struct sk_buff *pkt, int prec) 40 struct sk_buff *pkt, int prec)
@@ -246,6 +249,7 @@ int brcmf_c_preinit_dcmds(struct brcmf_if *ifp)
246{ 249{
247 s8 eventmask[BRCMF_EVENTING_MASK_LEN]; 250 s8 eventmask[BRCMF_EVENTING_MASK_LEN];
248 u8 buf[BRCMF_DCMD_SMLEN]; 251 u8 buf[BRCMF_DCMD_SMLEN];
252 struct brcmf_join_pref_params join_pref_params[2];
249 char *ptr; 253 char *ptr;
250 s32 err; 254 s32 err;
251 255
@@ -298,6 +302,20 @@ int brcmf_c_preinit_dcmds(struct brcmf_if *ifp)
298 goto done; 302 goto done;
299 } 303 }
300 304
305 /* Setup join_pref to select target by RSSI(with boost on 5GHz) */
306 join_pref_params[0].type = BRCMF_JOIN_PREF_RSSI_DELTA;
307 join_pref_params[0].len = 2;
308 join_pref_params[0].rssi_gain = BRCMF_JOIN_PREF_RSSI_BOOST;
309 join_pref_params[0].band = WLC_BAND_5G;
310 join_pref_params[1].type = BRCMF_JOIN_PREF_RSSI;
311 join_pref_params[1].len = 2;
312 join_pref_params[1].rssi_gain = 0;
313 join_pref_params[1].band = 0;
314 err = brcmf_fil_iovar_data_set(ifp, "join_pref", join_pref_params,
315 sizeof(join_pref_params));
316 if (err)
317 brcmf_err("Set join_pref error (%d)\n", err);
318
301 /* Setup event_msgs, enable E_IF */ 319 /* Setup event_msgs, enable E_IF */
302 err = brcmf_fil_iovar_data_get(ifp, "event_msgs", eventmask, 320 err = brcmf_fil_iovar_data_get(ifp, "event_msgs", eventmask,
303 BRCMF_EVENTING_MASK_LEN); 321 BRCMF_EVENTING_MASK_LEN);