summaryrefslogtreecommitdiff
path: root/net/mac80211
diff options
context:
space:
mode:
authorNicolas Cavallari <nicolas.cavallari@green-communications.fr>2022-10-27 17:01:33 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2022-12-02 19:39:57 +0300
commit2c1ca23555ed63ddca59a06214a96ab2bd417c48 (patch)
tree9a9a94087b4d7dfba3d3f33c74b93c53525cd063 /net/mac80211
parent8d39913158ad9e59642672ac03822848582c5767 (diff)
downloadlinux-2c1ca23555ed63ddca59a06214a96ab2bd417c48.tar.xz
wifi: mac80211: Fix ack frame idr leak when mesh has no route
[ Upstream commit 39e7b5de9853bd92ddbfa4b14165babacd7da0ba ] When trying to transmit an data frame with tx_status to a destination that have no route in the mesh, then it is dropped without recrediting the ack_status_frames idr. Once it is exhausted, wpa_supplicant starts failing to do SAE with NL80211_CMD_FRAME and logs "nl80211: Frame command failed". Use ieee80211_free_txskb() instead of kfree_skb() to fix it. Signed-off-by: Nicolas Cavallari <nicolas.cavallari@green-communications.fr> Link: https://lore.kernel.org/r/20221027140133.1504-1-nicolas.cavallari@green-communications.fr Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'net/mac80211')
-rw-r--r--net/mac80211/mesh_pathtbl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/mac80211/mesh_pathtbl.c b/net/mac80211/mesh_pathtbl.c
index 870c8eafef92..c2b051e0610a 100644
--- a/net/mac80211/mesh_pathtbl.c
+++ b/net/mac80211/mesh_pathtbl.c
@@ -718,7 +718,7 @@ int mesh_path_send_to_gates(struct mesh_path *mpath)
void mesh_path_discard_frame(struct ieee80211_sub_if_data *sdata,
struct sk_buff *skb)
{
- kfree_skb(skb);
+ ieee80211_free_txskb(&sdata->local->hw, skb);
sdata->u.mesh.mshstats.dropped_frames_no_route++;
}