Commit f83f1c12 authored by Johannes Berg's avatar Johannes Berg

mac80211: remove sta->tx_fragments counter

This counter is unsafe with concurrent TX and is only exposed
through debugfs and ethtool. Instead of trying to fix it just
remove it for now, if it's really needed then it should be
exposed through nl80211 and in a way that drivers that do the
fragmentation in the device could support it as well.
Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent c206ca67
...@@ -452,7 +452,6 @@ void ieee80211_sta_debugfs_add(struct sta_info *sta) ...@@ -452,7 +452,6 @@ void ieee80211_sta_debugfs_add(struct sta_info *sta)
DEBUGFS_ADD_COUNTER(rx_duplicates, num_duplicates); DEBUGFS_ADD_COUNTER(rx_duplicates, num_duplicates);
DEBUGFS_ADD_COUNTER(rx_fragments, rx_fragments); DEBUGFS_ADD_COUNTER(rx_fragments, rx_fragments);
DEBUGFS_ADD_COUNTER(rx_dropped, rx_dropped); DEBUGFS_ADD_COUNTER(rx_dropped, rx_dropped);
DEBUGFS_ADD_COUNTER(tx_fragments, tx_fragments);
DEBUGFS_ADD_COUNTER(tx_filtered, tx_filtered_count); DEBUGFS_ADD_COUNTER(tx_filtered, tx_filtered_count);
DEBUGFS_ADD_COUNTER(tx_retry_failed, tx_retry_failed); DEBUGFS_ADD_COUNTER(tx_retry_failed, tx_retry_failed);
DEBUGFS_ADD_COUNTER(tx_retry_count, tx_retry_count); DEBUGFS_ADD_COUNTER(tx_retry_count, tx_retry_count);
......
...@@ -38,7 +38,7 @@ static void ieee80211_get_ringparam(struct net_device *dev, ...@@ -38,7 +38,7 @@ static void ieee80211_get_ringparam(struct net_device *dev,
static const char ieee80211_gstrings_sta_stats[][ETH_GSTRING_LEN] = { static const char ieee80211_gstrings_sta_stats[][ETH_GSTRING_LEN] = {
"rx_packets", "rx_bytes", "rx_packets", "rx_bytes",
"rx_duplicates", "rx_fragments", "rx_dropped", "rx_duplicates", "rx_fragments", "rx_dropped",
"tx_packets", "tx_bytes", "tx_fragments", "tx_packets", "tx_bytes",
"tx_filtered", "tx_retry_failed", "tx_retries", "tx_filtered", "tx_retry_failed", "tx_retries",
"beacon_loss", "sta_state", "txrate", "rxrate", "signal", "beacon_loss", "sta_state", "txrate", "rxrate", "signal",
"channel", "noise", "ch_time", "ch_time_busy", "channel", "noise", "ch_time", "ch_time_busy",
...@@ -87,7 +87,6 @@ static void ieee80211_get_stats(struct net_device *dev, ...@@ -87,7 +87,6 @@ static void ieee80211_get_stats(struct net_device *dev,
\ \
data[i++] += sinfo.tx_packets; \ data[i++] += sinfo.tx_packets; \
data[i++] += sinfo.tx_bytes; \ data[i++] += sinfo.tx_bytes; \
data[i++] += sta->tx_fragments; \
data[i++] += sta->tx_filtered_count; \ data[i++] += sta->tx_filtered_count; \
data[i++] += sta->tx_retry_failed; \ data[i++] += sta->tx_retry_failed; \
data[i++] += sta->tx_retry_count; \ data[i++] += sta->tx_retry_count; \
......
...@@ -323,7 +323,6 @@ struct ieee80211_fast_tx { ...@@ -323,7 +323,6 @@ struct ieee80211_fast_tx {
* @fail_avg: moving percentage of failed MSDUs * @fail_avg: moving percentage of failed MSDUs
* @tx_packets: number of RX/TX MSDUs * @tx_packets: number of RX/TX MSDUs
* @tx_bytes: number of bytes transmitted to this STA * @tx_bytes: number of bytes transmitted to this STA
* @tx_fragments: number of transmitted MPDUs
* @tid_seq: per-TID sequence numbers for sending to this STA * @tid_seq: per-TID sequence numbers for sending to this STA
* @ampdu_mlme: A-MPDU state machine state * @ampdu_mlme: A-MPDU state machine state
* @timer_to_tid: identity mapping to ID timers * @timer_to_tid: identity mapping to ID timers
...@@ -433,7 +432,6 @@ struct sta_info { ...@@ -433,7 +432,6 @@ struct sta_info {
unsigned int fail_avg; unsigned int fail_avg;
/* Updated from TX path only, no locking requirements */ /* Updated from TX path only, no locking requirements */
u32 tx_fragments;
u64 tx_packets[IEEE80211_NUM_ACS]; u64 tx_packets[IEEE80211_NUM_ACS];
u64 tx_bytes[IEEE80211_NUM_ACS]; u64 tx_bytes[IEEE80211_NUM_ACS];
struct ieee80211_tx_rate last_tx_rate; struct ieee80211_tx_rate last_tx_rate;
......
...@@ -997,7 +997,6 @@ ieee80211_tx_h_stats(struct ieee80211_tx_data *tx) ...@@ -997,7 +997,6 @@ ieee80211_tx_h_stats(struct ieee80211_tx_data *tx)
skb_queue_walk(&tx->skbs, skb) { skb_queue_walk(&tx->skbs, skb) {
ac = skb_get_queue_mapping(skb); ac = skb_get_queue_mapping(skb);
tx->sta->tx_fragments++;
tx->sta->tx_bytes[ac] += skb->len; tx->sta->tx_bytes[ac] += skb->len;
} }
if (ac >= 0) if (ac >= 0)
...@@ -2804,7 +2803,6 @@ static bool ieee80211_xmit_fast(struct ieee80211_sub_if_data *sdata, ...@@ -2804,7 +2803,6 @@ static bool ieee80211_xmit_fast(struct ieee80211_sub_if_data *sdata,
/* statistics normally done by ieee80211_tx_h_stats (but that /* statistics normally done by ieee80211_tx_h_stats (but that
* has to consider fragmentation, so is more complex) * has to consider fragmentation, so is more complex)
*/ */
sta->tx_fragments++;
sta->tx_bytes[skb_get_queue_mapping(skb)] += skb->len; sta->tx_bytes[skb_get_queue_mapping(skb)] += skb->len;
sta->tx_packets[skb_get_queue_mapping(skb)]++; sta->tx_packets[skb_get_queue_mapping(skb)]++;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment