aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/mac80211/tx.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index b909e4090e93..a0e00c6339ca 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -1089,7 +1089,7 @@ static int __ieee80211_tx(struct ieee80211_local *local,
1089{ 1089{
1090 struct sk_buff *skb = *skbp, *next; 1090 struct sk_buff *skb = *skbp, *next;
1091 struct ieee80211_tx_info *info; 1091 struct ieee80211_tx_info *info;
1092 int ret; 1092 int ret, len;
1093 bool fragm = false; 1093 bool fragm = false;
1094 1094
1095 local->mdev->trans_start = jiffies; 1095 local->mdev->trans_start = jiffies;
@@ -1125,7 +1125,12 @@ static int __ieee80211_tx(struct ieee80211_local *local,
1125 } 1125 }
1126 1126
1127 next = skb->next; 1127 next = skb->next;
1128 len = skb->len;
1128 ret = local->ops->tx(local_to_hw(local), skb); 1129 ret = local->ops->tx(local_to_hw(local), skb);
1130 if (WARN_ON(ret != NETDEV_TX_OK && skb->len != len)) {
1131 dev_kfree_skb(skb);
1132 ret = NETDEV_TX_OK;
1133 }
1129 if (ret != NETDEV_TX_OK) 1134 if (ret != NETDEV_TX_OK)
1130 return IEEE80211_TX_AGAIN; 1135 return IEEE80211_TX_AGAIN;
1131 *skbp = skb = next; 1136 *skbp = skb = next;