ath9k: show excessive-retry MPDUs in debugfs
authorFelix Fietkau <nbd@openwrt.org>
Tue, 31 May 2011 19:21:41 +0000 (21:21 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 3 Jun 2011 19:01:07 +0000 (15:01 -0400)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/debug.c
drivers/net/wireless/ath/ath9k/debug.h

index 7230d6578b15d88b8821fabd42c584d174b32982..22d3a26e684d518a77f4af691943a0b035ce55c7 100644 (file)
@@ -600,6 +600,7 @@ static ssize_t read_file_xmit(struct file *file, char __user *user_buf,
 
        PR("MPDUs Queued:    ", queued);
        PR("MPDUs Completed: ", completed);
+       PR("MPDUs XRetried:  ", xretries);
        PR("Aggregates:      ", a_aggr);
        PR("AMPDUs Queued HW:", a_queued_hw);
        PR("AMPDUs Queued SW:", a_queued_sw);
@@ -856,7 +857,10 @@ void ath_debug_stat_tx(struct ath_softc *sc, struct ath_buf *bf,
                else
                        TX_STAT_INC(qnum, a_completed);
        } else {
-               TX_STAT_INC(qnum, completed);
+               if (bf_isxretried(bf))
+                       TX_STAT_INC(qnum, xretries);
+               else
+                       TX_STAT_INC(qnum, completed);
        }
 
        if (ts->ts_status & ATH9K_TXERR_FIFO)
index 8ce6ad80f4e208461469ecbb7b90172ae460a044..4a04510e1111c49845ceadb90f35deef2a670af7 100644 (file)
@@ -116,6 +116,7 @@ struct ath_tx_stats {
        u32 tx_bytes_all;
        u32 queued;
        u32 completed;
+       u32 xretries;
        u32 a_aggr;
        u32 a_queued_hw;
        u32 a_queued_sw;