diff options
author | Ben Greear <greearb@candelatech.com> | 2011-01-09 23:11:43 -0800 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-01-21 15:32:21 -0500 |
commit | 1f427dd913a1bf61f2d124d12a022ca2f1d27f53 (patch) | |
tree | ce40e74f7af21038fbe17fbd1f1467e8ffbf6b0b /drivers/net/wireless/ath/ath9k/debug.c | |
parent | b305dae488193b65cfa80e1c06c0aa0ce60005a9 (diff) | |
download | lwn-1f427dd913a1bf61f2d124d12a022ca2f1d27f53.tar.gz lwn-1f427dd913a1bf61f2d124d12a022ca2f1d27f53.zip |
ath9k: Show some live tx-queue values in debugfs.
I thought this might help track down stuck queues, etc.
Signed-off-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/debug.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/debug.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath9k/debug.c b/drivers/net/wireless/ath/ath9k/debug.c index 3586c43077a7..5075faa618d3 100644 --- a/drivers/net/wireless/ath/ath9k/debug.c +++ b/drivers/net/wireless/ath/ath9k/debug.c @@ -589,6 +589,16 @@ static const struct file_operations fops_wiphy = { sc->debug.stats.txstats[WME_AC_VO].elem); \ } while(0) +#define PRX(str, elem) \ +do { \ + len += snprintf(buf + len, size - len, \ + "%s%13u%11u%10u%10u\n", str, \ + (unsigned int)(sc->tx.txq[WME_AC_BE].elem), \ + (unsigned int)(sc->tx.txq[WME_AC_BK].elem), \ + (unsigned int)(sc->tx.txq[WME_AC_VI].elem), \ + (unsigned int)(sc->tx.txq[WME_AC_VO].elem)); \ +} while(0) + static ssize_t read_file_xmit(struct file *file, char __user *user_buf, size_t count, loff_t *ppos) { @@ -619,6 +629,12 @@ static ssize_t read_file_xmit(struct file *file, char __user *user_buf, PR("TX-Pkts-All: ", tx_pkts_all); PR("TX-Bytes-All: ", tx_bytes_all); + PRX("axq-qnum: ", axq_qnum); + PRX("axq-depth: ", axq_depth); + PRX("axq-stopped ", stopped); + PRX("tx-in-progress ", axq_tx_inprogress); + PRX("pending-frames ", pending_frames); + if (len > size) len = size; |