PERFORCE change 87095 for review

Sam Leffler sam at FreeBSD.org
Tue Nov 22 15:33:29 PST 2005


http://perforce.freebsd.org/chv.cgi?CH=87095

Change 87095 by sam at sam_ebb on 2005/11/22 23:33:07

	IFC

Affected files ...

.. //depot/projects/wifi/sys/dev/ath/ath_rate/sample/sample.c#7 integrate
.. //depot/projects/wifi/sys/dev/ath/if_ath.c#110 integrate
.. //depot/projects/wifi/sys/dev/ath/if_athioctl.h#10 integrate
.. //depot/projects/wifi/sys/dev/ath/if_athvar.h#45 integrate

Differences ...

==== //depot/projects/wifi/sys/dev/ath/ath_rate/sample/sample.c#7 (text+ko) ====

@@ -36,7 +36,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/ath/ath_rate/sample/sample.c,v 1.9 2005/07/22 16:50:17 sam Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/ath/ath_rate/sample/sample.c,v 1.10 2005/11/15 05:47:20 sam Exp $");
 
 /*
  * John Bicket's SampleRate control algorithm.
@@ -708,6 +708,11 @@
         for (x = 0; x < ni->ni_rates.rs_nrates; x++) {
 		sn->rates[x].rate = ni->ni_rates.rs_rates[x] & IEEE80211_RATE_VAL;
 		sn->rates[x].rix = sc->sc_rixmap[sn->rates[x].rate];
+		if (sn->rates[x].rix == 0xff) {
+			DPRINTF(sc, "%s: ignore bogus rix at %d\n",
+				__func__, x);
+			continue;
+		}
 		sn->rates[x].rateCode = rt->info[sn->rates[x].rix].rateCode;
 		sn->rates[x].shortPreambleRateCode = 
 			rt->info[sn->rates[x].rix].rateCode | 

==== //depot/projects/wifi/sys/dev/ath/if_ath.c#110 (text+ko) ====

@@ -35,7 +35,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.104 2005/09/16 10:09:23 ru Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.106 2005/11/15 05:49:02 sam Exp $");
 
 /*
  * Driver for the Atheros Wireless LAN controller.
@@ -3682,13 +3682,6 @@
 ath_tx_start(struct ath_softc *sc, struct ieee80211_node *ni, struct ath_buf *bf,
     struct mbuf *m0)
 {
-#define	CTS_DURATION \
-	ath_hal_computetxtime(ah, rt, IEEE80211_ACK_LEN, cix, AH_TRUE)
-#define	updateCTSForBursting(_ah, _ds, _txq) \
-	ath_hal_updateCTSForBursting(_ah, _ds, \
-	    _txq->axq_linkbuf != NULL ? _txq->axq_linkbuf->bf_desc : NULL, \
-	    _txq->axq_lastdsWithCTS, _txq->axq_gatingds, \
-	    txopLimit, CTS_DURATION)
 	struct ieee80211com *ic = &sc->sc_ic;
 	struct ath_hal *ah = sc->sc_ah;
 	struct ifnet *ifp = sc->sc_ifp;
@@ -4166,39 +4159,6 @@
 	 * pass it on to the hardware.
 	 */
 	ATH_TXQ_LOCK(txq);
-	if (flags & (HAL_TXDESC_RTSENA | HAL_TXDESC_CTSENA)) {
-		u_int32_t txopLimit = IEEE80211_TXOP_TO_US(
-			cap->cap_wmeParams[pri].wmep_txopLimit);
-		/*
-		 * When bursting, potentially extend the CTS duration
-		 * of a previously queued frame to cover this frame
-		 * and not exceed the txopLimit.  If that can be done
-		 * then disable RTS/CTS on this frame since it's now
-		 * covered (burst extension).  Otherwise we must terminate
-		 * the burst before this frame goes out so as not to
-		 * violate the WME parameters.  All this is complicated
-		 * as we need to update the state of packets on the
-		 * (live) hardware queue.  The logic is buried in the hal
-		 * because it's highly chip-specific.
-		 */
-		if (txopLimit != 0) {
-			sc->sc_stats.ast_tx_ctsburst++;
-			if (updateCTSForBursting(ah, ds0, txq) == 0) {
-				/*
-				 * This frame was not covered by RTS/CTS from
-				 * the previous frame in the burst; update the
-				 * descriptor pointers so this frame is now
-				 * treated as the last frame for extending a
-				 * burst.
-				 */
-				txq->axq_lastdsWithCTS = ds0;
-				/* set gating Desc to final desc */
-				txq->axq_gatingds =
-					(struct ath_desc *)txq->axq_link;
-			} else
-				sc->sc_stats.ast_tx_ctsext++;
-		}
-	}
 	ATH_TXQ_INSERT_TAIL(txq, bf, bf_list);
 	if (txq->axq_link == NULL) {
 		ath_hal_puttxbuf(ah, txq->axq_qnum, bf->bf_daddr);
@@ -4223,8 +4183,6 @@
 	ATH_TXQ_UNLOCK(txq);
 
 	return 0;
-#undef updateCTSForBursting
-#undef CTS_DURATION
 }
 
 /*
@@ -4267,10 +4225,6 @@
 			ATH_TXQ_UNLOCK(txq);
 			break;
 		}
-		if (ds0 == txq->axq_lastdsWithCTS)
-			txq->axq_lastdsWithCTS = NULL;
-		if (ds == txq->axq_gatingds)
-			txq->axq_gatingds = NULL;
 		ATH_TXQ_REMOVE_HEAD(txq, bf_list);
 		ATH_TXQ_UNLOCK(txq);
 

==== //depot/projects/wifi/sys/dev/ath/if_athioctl.h#10 (text+ko) ====

@@ -33,7 +33,7 @@
  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
  * THE POSSIBILITY OF SUCH DAMAGES.
  *
- * $FreeBSD: src/sys/dev/ath/if_athioctl.h,v 1.10 2005/03/30 20:13:08 sam Exp $
+ * $FreeBSD: src/sys/dev/ath/if_athioctl.h,v 1.11 2005/11/15 05:49:02 sam Exp $
  */
 
 /*
@@ -76,8 +76,8 @@
 	u_int32_t	ast_tx_shortpre;/* tx frames with short preamble */
 	u_int32_t	ast_tx_altrate;	/* tx frames with alternate rate */
 	u_int32_t	ast_tx_protect;	/* tx frames with protection */
-	u_int32_t	ast_tx_ctsburst;/* tx frames with cts and bursting */
-	u_int32_t	ast_tx_ctsext;	/* tx frames with cts extension */
+	u_int32_t	ast_unused1;
+	u_int32_t	ast_unused2;
 	u_int32_t	ast_rx_nombuf;	/* rx setup failed 'cuz no mbuf */
 	u_int32_t	ast_rx_busdma;	/* rx setup failed for dma resrcs */
 	u_int32_t	ast_rx_orn;	/* rx failed 'cuz of desc overrun */

==== //depot/projects/wifi/sys/dev/ath/if_athvar.h#45 (text+ko) ====

@@ -33,7 +33,7 @@
  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
  * THE POSSIBILITY OF SUCH DAMAGES.
  *
- * $FreeBSD: src/sys/dev/ath/if_athvar.h,v 1.29 2005/08/08 18:46:36 sam Exp $
+ * $FreeBSD: src/sys/dev/ath/if_athvar.h,v 1.30 2005/11/15 05:49:02 sam Exp $
  */
 
 /*
@@ -150,19 +150,6 @@
 	STAILQ_HEAD(, ath_buf)	axq_q;		/* transmit queue */
 	struct mtx		axq_lock;	/* lock on q and link */
 	/*
-	 * State for patching up CTS when bursting.
-	 */
-	struct	ath_buf		*axq_linkbuf;	/* va of last buffer */
-	struct	ath_desc	*axq_lastdsWithCTS;
-						/* first desc of last descriptor
-						 * that contains CTS 
-						 */
-	struct	ath_desc	*axq_gatingds;	/* final desc of the gating desc
-						 * that determines whether
-						 * lastdsWithCTS has been DMA'ed
-						 * or not
-						 */
-	/*
 	 * Fast-frame state.  The staging queue holds awaiting
 	 * a fast-frame pairing.  Buffers on this queue are
 	 * assigned an ``age'' and flushed when they wait too long.
@@ -183,7 +170,6 @@
 	STAILQ_INSERT_TAIL(&(_tq)->axq_q, (_elm), _field); \
 	(_tq)->axq_depth++; \
 	(_tq)->axq_curage++; \
-	(_tq)->axq_linkbuf = (_elm); \
 } while (0)
 #define ATH_TXQ_REMOVE_HEAD(_tq, _field) do { \
 	STAILQ_REMOVE_HEAD(&(_tq)->axq_q, _field); \
@@ -562,10 +548,6 @@
 	((*(_ah)->ah_procTxDesc)((_ah), (_ds)))
 #define	ath_hal_gettxintrtxqs(_ah, _txqs) \
 	((*(_ah)->ah_getTxIntrQueue)((_ah), (_txqs)))
-#define	ath_hal_updateCTSForBursting(_ah, _ds, _prevds, _prevdsWithCTS, \
-		_gatingds,  _txOpLimit, _ctsDuration) \
-	((*(_ah)->ah_updateCTSForBursting)((_ah), (_ds), (_prevds), \
-		(_prevdsWithCTS), (_gatingds), (_txOpLimit), (_ctsDuration)))
 
 #define ath_hal_gpioCfgOutput(_ah, _gpio) \
         ((*(_ah)->ah_gpioCfgOutput)((_ah), (_gpio)))


More information about the p4-projects mailing list