aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChun-Yeow Yeoh <yeohchunyeow@gmail.com>2013-12-05 22:28:02 -0500
committerJohn W. Linville <linville@tuxdriver.com>2013-12-09 15:37:55 -0500
commitfa643ae2ce4e75413623a51845a2fd5c9fae4ec0 (patch)
tree194637447cfd6a4dd29501621c3f036461b906a8
parent997b179ba3d4da8a25d28cf4f1de8962a32e588a (diff)
wcn36xx: enable the beaconing in mesh mode
Enable the beaconing in wnc36xx by tweaking the tim offset and force the use of AP-style beaconing. Otherwise, beaconing is not working. The tim offset is set to 256. Otherwise, this will overwrite mesh beacon submitted by mac80211. Signed-off-by: Chun-Yeow Yeoh <yeohchunyeow@cozybit.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r--drivers/net/wireless/ath/wcn36xx/smd.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/drivers/net/wireless/ath/wcn36xx/smd.c b/drivers/net/wireless/ath/wcn36xx/smd.c
index 823631cdb872..8f37562e0b11 100644
--- a/drivers/net/wireless/ath/wcn36xx/smd.c
+++ b/drivers/net/wireless/ath/wcn36xx/smd.c
@@ -1151,14 +1151,14 @@ int wcn36xx_smd_config_bss(struct wcn36xx *wcn, struct ieee80211_vif *vif,
1151 /* STA */ 1151 /* STA */
1152 bss->oper_mode = 1; 1152 bss->oper_mode = 1;
1153 bss->wcn36xx_hal_persona = WCN36XX_HAL_STA_MODE; 1153 bss->wcn36xx_hal_persona = WCN36XX_HAL_STA_MODE;
1154 } else if (vif->type == NL80211_IFTYPE_AP) { 1154 } else if (vif->type == NL80211_IFTYPE_AP ||
1155 vif->type == NL80211_IFTYPE_MESH_POINT) {
1155 bss->bss_type = WCN36XX_HAL_INFRA_AP_MODE; 1156 bss->bss_type = WCN36XX_HAL_INFRA_AP_MODE;
1156 1157
1157 /* AP */ 1158 /* AP */
1158 bss->oper_mode = 0; 1159 bss->oper_mode = 0;
1159 bss->wcn36xx_hal_persona = WCN36XX_HAL_STA_SAP_MODE; 1160 bss->wcn36xx_hal_persona = WCN36XX_HAL_STA_SAP_MODE;
1160 } else if (vif->type == NL80211_IFTYPE_ADHOC || 1161 } else if (vif->type == NL80211_IFTYPE_ADHOC) {
1161 vif->type == NL80211_IFTYPE_MESH_POINT) {
1162 bss->bss_type = WCN36XX_HAL_IBSS_MODE; 1162 bss->bss_type = WCN36XX_HAL_IBSS_MODE;
1163 1163
1164 /* STA */ 1164 /* STA */
@@ -1309,7 +1309,11 @@ int wcn36xx_smd_send_beacon(struct wcn36xx *wcn, struct ieee80211_vif *vif,
1309 memcpy(msg_body.bssid, vif->addr, ETH_ALEN); 1309 memcpy(msg_body.bssid, vif->addr, ETH_ALEN);
1310 1310
1311 /* TODO need to find out why this is needed? */ 1311 /* TODO need to find out why this is needed? */
1312 msg_body.tim_ie_offset = tim_off+4; 1312 if (vif->type == NL80211_IFTYPE_MESH_POINT)
1313 /* mesh beacon don't need this, so push further down */
1314 msg_body.tim_ie_offset = 256;
1315 else
1316 msg_body.tim_ie_offset = tim_off+4;
1313 msg_body.p2p_ie_offset = p2p_off; 1317 msg_body.p2p_ie_offset = p2p_off;
1314 PREPARE_HAL_BUF(wcn->hal_buf, msg_body); 1318 PREPARE_HAL_BUF(wcn->hal_buf, msg_body);
1315 1319