mac80211: add fixes for receiving A-MSDU packets on mesh interfaces
[openwrt/staging/noltari.git] / package / kernel / mac80211 / patches / subsys / 314-wifi-mac80211-remove-mesh-forwarding-congestion-chec.patch
1 From: Felix Fietkau <nbd@nbd.name>
2 Date: Fri, 2 Dec 2022 17:01:46 +0100
3 Subject: [PATCH] wifi: mac80211: remove mesh forwarding congestion check
4
5 Now that all drivers use iTXQ, it does not make sense to check to drop
6 tx forwarding packets when the driver has stopped the queues.
7 fq_codel will take care of dropping packets when the queues fill up
8
9 Signed-off-by: Felix Fietkau <nbd@nbd.name>
10 ---
11
12 --- a/net/mac80211/debugfs_netdev.c
13 +++ b/net/mac80211/debugfs_netdev.c
14 @@ -603,8 +603,6 @@ IEEE80211_IF_FILE(fwded_mcast, u.mesh.ms
15 IEEE80211_IF_FILE(fwded_unicast, u.mesh.mshstats.fwded_unicast, DEC);
16 IEEE80211_IF_FILE(fwded_frames, u.mesh.mshstats.fwded_frames, DEC);
17 IEEE80211_IF_FILE(dropped_frames_ttl, u.mesh.mshstats.dropped_frames_ttl, DEC);
18 -IEEE80211_IF_FILE(dropped_frames_congestion,
19 - u.mesh.mshstats.dropped_frames_congestion, DEC);
20 IEEE80211_IF_FILE(dropped_frames_no_route,
21 u.mesh.mshstats.dropped_frames_no_route, DEC);
22
23 @@ -740,7 +738,6 @@ static void add_mesh_stats(struct ieee80
24 MESHSTATS_ADD(fwded_frames);
25 MESHSTATS_ADD(dropped_frames_ttl);
26 MESHSTATS_ADD(dropped_frames_no_route);
27 - MESHSTATS_ADD(dropped_frames_congestion);
28 #undef MESHSTATS_ADD
29 }
30
31 --- a/net/mac80211/ieee80211_i.h
32 +++ b/net/mac80211/ieee80211_i.h
33 @@ -329,7 +329,6 @@ struct mesh_stats {
34 __u32 fwded_frames; /* Mesh total forwarded frames */
35 __u32 dropped_frames_ttl; /* Not transmitted since mesh_ttl == 0*/
36 __u32 dropped_frames_no_route; /* Not transmitted, no route found */
37 - __u32 dropped_frames_congestion;/* Not forwarded due to congestion */
38 };
39
40 #define PREQ_Q_F_START 0x1
41 --- a/net/mac80211/rx.c
42 +++ b/net/mac80211/rx.c
43 @@ -2926,11 +2926,6 @@ ieee80211_rx_h_mesh_fwding(struct ieee80
44 return RX_CONTINUE;
45
46 ac = ieee802_1d_to_ac[skb->priority];
47 - q = sdata->vif.hw_queue[ac];
48 - if (ieee80211_queue_stopped(&local->hw, q)) {
49 - IEEE80211_IFSTA_MESH_CTR_INC(ifmsh, dropped_frames_congestion);
50 - return RX_DROP_MONITOR;
51 - }
52 skb_set_queue_mapping(skb, ac);
53
54 if (!--mesh_hdr->ttl) {