Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 17 Aug 2011 15:45:40 +0000 (UTC)
From:      Adrian Chadd <adrian@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-user@freebsd.org
Subject:   svn commit: r224947 - user/adrian/if_ath_tx/sys/dev/ath
Message-ID:  <201108171545.p7HFjeW2011982@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: adrian
Date: Wed Aug 17 15:45:40 2011
New Revision: 224947
URL: http://svn.freebsd.org/changeset/base/224947

Log:
  Fix some BAW brokenness introduced by previous commits.
  
  The BAW tracking was completely broken. ath_tx_swq() was blanking the BAW
  flag in the ath_buf, thus no frames were ever thrown into the BAW tracking
  code.
  
  This restores the BAW tracking functionality but there's again a race between
  the pre-ADDBA sequence numbers and the post-ADDBA BAW. I'll look into this
  and fix it in a subsequent commit.

Modified:
  user/adrian/if_ath_tx/sys/dev/ath/if_ath_tx.c

Modified: user/adrian/if_ath_tx/sys/dev/ath/if_ath_tx.c
==============================================================================
--- user/adrian/if_ath_tx/sys/dev/ath/if_ath_tx.c	Wed Aug 17 15:24:25 2011	(r224946)
+++ user/adrian/if_ath_tx/sys/dev/ath/if_ath_tx.c	Wed Aug 17 15:45:40 2011	(r224947)
@@ -1097,6 +1097,8 @@ ath_tx_start(struct ath_softc *sc, struc
 		txq = &avp->av_mcastq;
 
 	/* Do the generic frame setup */
+	/* XXX should just bzero the bf_state? */
+	bf->bf_state.bfs_dobaw = 0;
 
 	/* A-MPDU TX? Manually set sequence number */
 	/* Don't do it whilst pending; the net80211 layer still assigns them */
@@ -1247,6 +1249,10 @@ ath_tx_raw_start(struct ath_softc *sc, s
 	/* packet header may have moved, reset our local pointer */
 	wh = mtod(m0, struct ieee80211_frame *);
 
+	/* Do the generic frame setup */
+	/* XXX should just bzero the bf_state? */
+	bf->bf_state.bfs_dobaw = 0;
+
 	error = ath_tx_dmasetup(sc, bf, m0);
 	if (error != 0)
 		return error;
@@ -1780,7 +1786,6 @@ ath_tx_swq(struct ath_softc *sc, struct 
 	bf->bf_state.bfs_tid = tid;
 	bf->bf_state.bfs_txq = txq;
 	bf->bf_state.bfs_pri = pri;
-	bf->bf_state.bfs_dobaw = 0;
 	bf->bf_state.bfs_aggr = 0;
 	bf->bf_state.bfs_aggrburst = 0;
 
@@ -2581,6 +2586,7 @@ ath_tx_tid_hw_queue_aggr(struct ath_soft
 			    "%s: seq %d outside of %d/%d; waiting\n",
 			    __func__, SEQNO(bf->bf_state.bfs_seqno),
 			    tap->txa_start, tap->txa_wnd);
+			ATH_TXQ_UNLOCK(atid);
 			break;
 		}
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201108171545.p7HFjeW2011982>