Skip to contentSkip to conversation

wlcore: flush tx on CHANGE_CHANNEL

PATCH In review Arik Nemtsov 2 participants 4 messages May 15, 2012 – Jun 6, 2012 TI wilink wireless drivers

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/3 wlcore: flush tx on CHANGE_CHANNEL

From: Eliad Peller <[email protected]>

On CHANGE_CHANNEL indication, we should flush all the queued tx frames, so they will be sent on the correct (current) channel.

---
v1->2: added SOB tag by eliad

 drivers/net/wireless/ti/wlcore/main.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
drivers/net/wireless/ti/wlcore/main.c +3 -2
index ebbedbf..4e71078 100644
@@ -2553,8 +2553,9 @@ static int wl1271_op_config(struct ieee80211_hw *hw, u32 changed)
 	 * frames, such as the deauth. To make sure those frames reach the air,
 	 * wait here until the TX queue is fully flushed.
 	 */
-	if ((changed & IEEE80211_CONF_CHANGE_IDLE) &&
-	    (conf->flags & IEEE80211_CONF_IDLE))
+	if ((changed & IEEE80211_CONF_CHANGE_CHANNEL) ||
+	    ((changed & IEEE80211_CONF_CHANGE_IDLE) &&
+	     (conf->flags & IEEE80211_CONF_IDLE)))
 		wl1271_tx_flush(wl);
 
 	mutex_lock(&wl->mutex);
Signature · 1 line
1.7.9.5
#1 lore raw

PATCH v2 2/3 wlcore: increase WL1271_EVENT_TIMEOUT

From: Eliad Peller <[email protected]>

In some cases, the ROC_COMPLETE event might exceed the current timeout (750 msec). Increase it to 1 sec.

---
 drivers/net/wireless/ti/wlcore/cmd.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/wireless/ti/wlcore/cmd.h +1 -1
index 2aafe3d..85171f2 100644
@@ -192,7 +192,7 @@ enum cmd_templ {
 #define WL1271_COMMAND_TIMEOUT     2000
 #define WL1271_CMD_TEMPL_DFLT_SIZE 252
 #define WL1271_CMD_TEMPL_MAX_SIZE  512
-#define WL1271_EVENT_TIMEOUT       750
+#define WL1271_EVENT_TIMEOUT       1000
 
 struct wl1271_cmd_header {
 	__le16 id;
Signature · 1 line
1.7.9.5
#2 lore raw

PATCH v2 3/3 wlcore: remove duplicate BUG_ON during recovery

In reply to Arik Nemtsov

This BUG_ON also ignored the INTENDED_FW_RECOVERY flag. This would result in a BUG() when using the bug_on_recovery module parameter during multi-role.

---
 drivers/net/wireless/ti/wlcore/main.c |    2 --
 1 file changed, 2 deletions(-)
drivers/net/wireless/ti/wlcore/main.c +0 -2
index 4e71078..f4b036e 100644
@@ -852,8 +852,6 @@ static void wl1271_recovery_work(struct work_struct *work)
 		goto out_unlock;
 	}
 
-	BUG_ON(bug_on_recovery);
-
 	/*
 	 * Advance security sequence number to overcome potential progress
 	 * in the firmware during recovery. This doens't hurt if the network is
Signature · 1 line
1.7.9.5