mirror of https://gitee.com/openkylin/linux.git
mac80211_hwsim: use ieee80211_free_txskb
These are only strange error cases, so it's not really all that important, but the driver really should use ieee80211_free_txskb() instead of just dev_kfree_skb(). Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
parent
b60e527a72
commit
fe0f3cd2a6
|
@ -867,7 +867,7 @@ static void mac80211_hwsim_tx(struct ieee80211_hw *hw,
|
||||||
|
|
||||||
if (WARN_ON(skb->len < 10)) {
|
if (WARN_ON(skb->len < 10)) {
|
||||||
/* Should not happen; just a sanity check for addr1 use */
|
/* Should not happen; just a sanity check for addr1 use */
|
||||||
dev_kfree_skb(skb);
|
ieee80211_free_txskb(hw, skb);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -884,13 +884,13 @@ static void mac80211_hwsim_tx(struct ieee80211_hw *hw,
|
||||||
}
|
}
|
||||||
|
|
||||||
if (WARN(!channel, "TX w/o channel - queue = %d\n", txi->hw_queue)) {
|
if (WARN(!channel, "TX w/o channel - queue = %d\n", txi->hw_queue)) {
|
||||||
dev_kfree_skb(skb);
|
ieee80211_free_txskb(hw, skb);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (data->idle && !data->tmp_chan) {
|
if (data->idle && !data->tmp_chan) {
|
||||||
wiphy_debug(hw->wiphy, "Trying to TX when idle - reject\n");
|
wiphy_debug(hw->wiphy, "Trying to TX when idle - reject\n");
|
||||||
dev_kfree_skb(skb);
|
ieee80211_free_txskb(hw, skb);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue