diff options
author | Oleksij Rempel <linux@rempel-privat.de> | 2014-05-11 04:04:36 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2014-05-13 15:56:40 -0400 |
commit | b5a0c86a56e4494eab84b142ab5501eb62685150 (patch) | |
tree | dab4503f829565ff87c04030e63b3d6dd20728b7 /drivers/net/wireless/ath/ath9k/debug.c | |
parent | 9d83cd5cd2e43f7f24feec66f8d15457589f7033 (diff) |
ath9k & ath9k_htc: move ath_rx_stats to cmn
and use it. This move need changes in both drivers.
Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
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 | 26 |
1 files changed, 1 insertions, 25 deletions
diff --git a/drivers/net/wireless/ath/ath9k/debug.c b/drivers/net/wireless/ath/ath9k/debug.c index 361f07937a7a..be29e71625cd 100644 --- a/drivers/net/wireless/ath/ath9k/debug.c +++ b/drivers/net/wireless/ath/ath9k/debug.c | |||
@@ -998,31 +998,7 @@ static ssize_t read_file_recv(struct file *file, char __user *user_buf, | |||
998 | 998 | ||
999 | void ath_debug_stat_rx(struct ath_softc *sc, struct ath_rx_status *rs) | 999 | void ath_debug_stat_rx(struct ath_softc *sc, struct ath_rx_status *rs) |
1000 | { | 1000 | { |
1001 | #define RX_PHY_ERR_INC(c) sc->debug.stats.rxstats.phy_err_stats[c]++ | 1001 | ath9k_cmn_debug_stat_rx(&sc->debug.stats.rxstats, rs); |
1002 | |||
1003 | RX_STAT_INC(rx_pkts_all); | ||
1004 | sc->debug.stats.rxstats.rx_bytes_all += rs->rs_datalen; | ||
1005 | |||
1006 | if (rs->rs_status & ATH9K_RXERR_CRC) | ||
1007 | RX_STAT_INC(crc_err); | ||
1008 | if (rs->rs_status & ATH9K_RXERR_DECRYPT) | ||
1009 | RX_STAT_INC(decrypt_crc_err); | ||
1010 | if (rs->rs_status & ATH9K_RXERR_MIC) | ||
1011 | RX_STAT_INC(mic_err); | ||
1012 | if (rs->rs_status & ATH9K_RX_DELIM_CRC_PRE) | ||
1013 | RX_STAT_INC(pre_delim_crc_err); | ||
1014 | if (rs->rs_status & ATH9K_RX_DELIM_CRC_POST) | ||
1015 | RX_STAT_INC(post_delim_crc_err); | ||
1016 | if (rs->rs_status & ATH9K_RX_DECRYPT_BUSY) | ||
1017 | RX_STAT_INC(decrypt_busy_err); | ||
1018 | |||
1019 | if (rs->rs_status & ATH9K_RXERR_PHY) { | ||
1020 | RX_STAT_INC(phy_err); | ||
1021 | if (rs->rs_phyerr < ATH9K_PHYERR_MAX) | ||
1022 | RX_PHY_ERR_INC(rs->rs_phyerr); | ||
1023 | } | ||
1024 | |||
1025 | #undef RX_PHY_ERR_INC | ||
1026 | } | 1002 | } |
1027 | 1003 | ||
1028 | static const struct file_operations fops_recv = { | 1004 | static const struct file_operations fops_recv = { |