07b30dfbf733b9a77c97b9c9bb5ce880c270cff4
[openwrt/staging/jow.git] /
1 From: Felix Fietkau <nbd@nbd.name>
2 Date: Mon, 25 Mar 2019 09:02:13 +0100
3 Subject: [PATCH] mac80211: minstrel_ht: add support for rates with 4
4 spatial streams
5
6 This is needed for the upcoming driver for MT7615 4x4 802.11ac chipsets
7
8 Signed-off-by: Felix Fietkau <nbd@nbd.name>
9 ---
10
11 --- a/net/mac80211/rc80211_minstrel_ht.c
12 +++ b/net/mac80211/rc80211_minstrel_ht.c
13 @@ -157,44 +157,54 @@ const struct mcs_group minstrel_mcs_grou
14 MCS_GROUP(1, 0, BW_20, 5),
15 MCS_GROUP(2, 0, BW_20, 4),
16 MCS_GROUP(3, 0, BW_20, 4),
17 + MCS_GROUP(4, 0, BW_20, 4),
18
19 MCS_GROUP(1, 1, BW_20, 5),
20 MCS_GROUP(2, 1, BW_20, 4),
21 MCS_GROUP(3, 1, BW_20, 4),
22 + MCS_GROUP(4, 1, BW_20, 4),
23
24 MCS_GROUP(1, 0, BW_40, 4),
25 MCS_GROUP(2, 0, BW_40, 4),
26 MCS_GROUP(3, 0, BW_40, 4),
27 + MCS_GROUP(4, 0, BW_40, 4),
28
29 MCS_GROUP(1, 1, BW_40, 4),
30 MCS_GROUP(2, 1, BW_40, 4),
31 MCS_GROUP(3, 1, BW_40, 4),
32 + MCS_GROUP(4, 1, BW_40, 4),
33
34 CCK_GROUP(8),
35
36 VHT_GROUP(1, 0, BW_20, 5),
37 VHT_GROUP(2, 0, BW_20, 4),
38 VHT_GROUP(3, 0, BW_20, 4),
39 + VHT_GROUP(4, 0, BW_20, 4),
40
41 VHT_GROUP(1, 1, BW_20, 5),
42 VHT_GROUP(2, 1, BW_20, 4),
43 VHT_GROUP(3, 1, BW_20, 4),
44 + VHT_GROUP(4, 1, BW_20, 4),
45
46 VHT_GROUP(1, 0, BW_40, 4),
47 VHT_GROUP(2, 0, BW_40, 4),
48 VHT_GROUP(3, 0, BW_40, 4),
49 + VHT_GROUP(4, 0, BW_40, 3),
50
51 VHT_GROUP(1, 1, BW_40, 4),
52 VHT_GROUP(2, 1, BW_40, 4),
53 VHT_GROUP(3, 1, BW_40, 4),
54 + VHT_GROUP(4, 1, BW_40, 3),
55
56 VHT_GROUP(1, 0, BW_80, 4),
57 VHT_GROUP(2, 0, BW_80, 4),
58 VHT_GROUP(3, 0, BW_80, 4),
59 + VHT_GROUP(4, 0, BW_80, 2),
60
61 VHT_GROUP(1, 1, BW_80, 4),
62 VHT_GROUP(2, 1, BW_80, 4),
63 VHT_GROUP(3, 1, BW_80, 4),
64 + VHT_GROUP(4, 1, BW_80, 2),
65 };
66
67 static u8 sample_table[SAMPLE_COLUMNS][MCS_GROUP_RATES] __read_mostly;
68 --- a/net/mac80211/rc80211_minstrel_ht.h
69 +++ b/net/mac80211/rc80211_minstrel_ht.h
70 @@ -13,7 +13,7 @@
71 * The number of streams can be changed to 2 to reduce code
72 * size and memory footprint.
73 */
74 -#define MINSTREL_MAX_STREAMS 3
75 +#define MINSTREL_MAX_STREAMS 4
76 #define MINSTREL_HT_STREAM_GROUPS 4 /* BW(=2) * SGI(=2) */
77 #define MINSTREL_VHT_STREAM_GROUPS 6 /* BW(=3) * SGI(=2) */
78