Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 12 Sep 2016 04:50:40 +0000 (UTC)
From:      Adrian Chadd <adrian@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r305720 - head/sys/dev/ath
Message-ID:  <201609120450.u8C4oewv048932@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: adrian
Date: Mon Sep 12 04:50:40 2016
New Revision: 305720
URL: https://svnweb.freebsd.org/changeset/base/305720

Log:
  [ath] tweak the TX EDMA debugging a bit.
  
  I've used this to debug some amusing issues with the EDMA code.
  
  Tested:
  
  * AR9380, STA mode
  * AR9380, TDMA mode (master, slave)

Modified:
  head/sys/dev/ath/if_ath_tx_edma.c

Modified: head/sys/dev/ath/if_ath_tx_edma.c
==============================================================================
--- head/sys/dev/ath/if_ath_tx_edma.c	Mon Sep 12 01:18:25 2016	(r305719)
+++ head/sys/dev/ath/if_ath_tx_edma.c	Mon Sep 12 04:50:40 2016	(r305720)
@@ -268,7 +268,7 @@ ath_tx_edma_push_staging_list(struct ath
 
 	/* Bump FIFO queue */
 	txq->axq_fifo_depth++;
-	DPRINTF(sc, ATH_DEBUG_XMIT,
+	DPRINTF(sc, ATH_DEBUG_XMIT | ATH_DEBUG_TX_PROC,
 	    "%s: queued %d packets; depth=%d, fifo depth=%d\n",
 	    __func__, sqdepth, txq->fifo.axq_depth, txq->axq_fifo_depth);
 
@@ -296,16 +296,21 @@ ath_edma_tx_fifo_fill(struct ath_softc *
 
 	ATH_TXQ_LOCK_ASSERT(txq);
 
-	DPRINTF(sc, ATH_DEBUG_TX_PROC, "%s: Q%d: called\n",
+	DPRINTF(sc, ATH_DEBUG_TX_PROC,
+	    "%s: Q%d: called; fifo.depth=%d, fifo depth=%d, depth=%d, aggr_depth=%d\n",
 	    __func__,
-	    txq->axq_qnum);
+	    txq->axq_qnum,
+	    txq->fifo.axq_depth,
+	    txq->axq_fifo_depth,
+	    txq->axq_depth,
+	    txq->axq_aggr_depth);
 
 	/*
-	 * For now, push up to 4 frames per TX FIFO slot.
+	 * For now, push up to 32 frames per TX FIFO slot.
 	 * If more are in the hardware queue then they'll
 	 * get populated when we try to send another frame
 	 * or complete a frame - so at most there'll be
-	 * 32 non-AMPDU frames per TXQ.
+	 * 32 non-AMPDU frames per node/TID anyway.
 	 *
 	 * Note that the hardware staging queue will limit
 	 * how many frames in total we will have pushed into
@@ -811,10 +816,11 @@ ath_edma_tx_processq(struct ath_softc *s
 		}
 
 #if defined(ATH_DEBUG_ALQ) && defined(ATH_DEBUG)
-		if (if_ath_alq_checkdebug(&sc->sc_alq, ATH_ALQ_EDMA_TXSTATUS))
+		if (if_ath_alq_checkdebug(&sc->sc_alq, ATH_ALQ_EDMA_TXSTATUS)) {
 			if_ath_alq_post(&sc->sc_alq, ATH_ALQ_EDMA_TXSTATUS,
 			    sc->sc_tx_statuslen,
 			    (char *) txstatus);
+		}
 #endif /* ATH_DEBUG_ALQ */
 
 		/*



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