Skip to content

Commit 7a7f7ed

Browse files
pseidererawanga
authored andcommitted
package/rtl8821au: add two patches fixing compile/runtime for kernels >= 5.3
Add two patches from upstream merge request ([1] to fix compile and runtime failures in case of linux kernel >= 5.3. [1] abperiasamy/rtl8812AU_8821AU_linux#316 Signed-off-by: Peter Seiderer <ps.report@gmx.net> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
1 parent d58b952 commit 7a7f7ed

File tree

2 files changed

+196
-0
lines changed

2 files changed

+196
-0
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
From f41695e4069404639690d98c7aadfe72117965a6 Mon Sep 17 00:00:00 2001
2+
From: Jesper Skov <jb1811@jyskebank.dk>
3+
Date: Fri, 25 Oct 2019 10:05:41 +0200
4+
Subject: [PATCH] Fix implicit fallthrough comments for kernel 5.3
5+
6+
[Upstram: https://github.com/abperiasamy/rtl8812AU_8821AU_linux/commit/e8a30a4c5a80efbbd5b1dbfe11b22916df4492f9.patch]
7+
Signed-off-by: Peter Seiderer <ps.report@gmx.net>
8+
---
9+
core/rtw_mlme_ext.c | 2 ++
10+
1 file changed, 2 insertions(+)
11+
12+
diff --git a/core/rtw_mlme_ext.c b/core/rtw_mlme_ext.c
13+
index 24565ea..380f507 100644
14+
--- a/core/rtw_mlme_ext.c
15+
+++ b/core/rtw_mlme_ext.c
16+
@@ -758,7 +758,9 @@ void mgt_dispatcher(_adapter *padapter, union recv_frame *precv_frame)
17+
else
18+
ptable->func = &OnAuthClient;
19+
//pass through
20+
+ //fallthrough
21+
case WIFI_ASSOCREQ:
22+
+ //fallthrough
23+
case WIFI_REASSOCREQ:
24+
_mgt_dispatcher(padapter, ptable, precv_frame);
25+
#ifdef CONFIG_HOSTAPD_MLME
26+
--
27+
2.26.0
28+
Lines changed: 168 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,168 @@
1+
From b7f8f8572d5abca6e1f0163a583628c0207d0be4 Mon Sep 17 00:00:00 2001
2+
From: Jesper Skov <jb1811@jyskebank.dk>
3+
Date: Fri, 25 Oct 2019 10:10:29 +0200
4+
Subject: [PATCH] Fix kernel 5.3 driver crashes, from aircrack-ng/rtl8812au#421
5+
6+
[Upstream: https://github.com/abperiasamy/rtl8812AU_8821AU_linux/commit/822b485d36d6f72304a219c3be228f40968b542b.patch]
7+
Signed-off-by: Peter Seiderer <ps.report@gmx.net>
8+
---
9+
os_dep/linux/rtw_cfgvendor.c | 45 ++++++++++++++++++++++++++++++++++++
10+
1 file changed, 45 insertions(+)
11+
12+
diff --git a/os_dep/linux/rtw_cfgvendor.c b/os_dep/linux/rtw_cfgvendor.c
13+
index e7ba90a..81fc8af 100644
14+
--- a/os_dep/linux/rtw_cfgvendor.c
15+
+++ b/os_dep/linux/rtw_cfgvendor.c
16+
@@ -1173,6 +1173,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
17+
.subcmd = BRCM_VENDOR_SCMD_PRIV_STR
18+
},
19+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
20+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
21+
+ .policy = VENDOR_CMD_RAW_DATA,
22+
+#endif
23+
.doit = wl_cfgvendor_priv_string_handler
24+
},
25+
#if defined(GSCAN_SUPPORT) && 0
26+
@@ -1182,6 +1185,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
27+
.subcmd = GSCAN_SUBCMD_GET_CAPABILITIES
28+
},
29+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
30+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
31+
+ .policy = VENDOR_CMD_RAW_DATA,
32+
+#endif
33+
.doit = wl_cfgvendor_gscan_get_capabilities
34+
},
35+
{
36+
@@ -1190,6 +1196,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
37+
.subcmd = GSCAN_SUBCMD_SET_CONFIG
38+
},
39+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
40+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
41+
+ .policy = VENDOR_CMD_RAW_DATA,
42+
+#endif
43+
.doit = wl_cfgvendor_set_scan_cfg
44+
},
45+
{
46+
@@ -1198,6 +1207,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
47+
.subcmd = GSCAN_SUBCMD_SET_SCAN_CONFIG
48+
},
49+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
50+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
51+
+ .policy = VENDOR_CMD_RAW_DATA,
52+
+#endif
53+
.doit = wl_cfgvendor_set_batch_scan_cfg
54+
},
55+
{
56+
@@ -1206,6 +1218,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
57+
.subcmd = GSCAN_SUBCMD_ENABLE_GSCAN
58+
},
59+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
60+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
61+
+ .policy = VENDOR_CMD_RAW_DATA,
62+
+#endif
63+
.doit = wl_cfgvendor_initiate_gscan
64+
},
65+
{
66+
@@ -1214,6 +1229,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
67+
.subcmd = GSCAN_SUBCMD_ENABLE_FULL_SCAN_RESULTS
68+
},
69+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
70+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
71+
+ .policy = VENDOR_CMD_RAW_DATA,
72+
+#endif
73+
.doit = wl_cfgvendor_enable_full_scan_result
74+
},
75+
{
76+
@@ -1222,6 +1240,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
77+
.subcmd = GSCAN_SUBCMD_SET_HOTLIST
78+
},
79+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
80+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
81+
+ .policy = VENDOR_CMD_RAW_DATA,
82+
+#endif
83+
.doit = wl_cfgvendor_hotlist_cfg
84+
},
85+
{
86+
@@ -1230,6 +1251,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
87+
.subcmd = GSCAN_SUBCMD_SET_SIGNIFICANT_CHANGE_CONFIG
88+
},
89+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
90+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
91+
+ .policy = VENDOR_CMD_RAW_DATA,
92+
+#endif
93+
.doit = wl_cfgvendor_significant_change_cfg
94+
},
95+
{
96+
@@ -1238,6 +1262,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
97+
.subcmd = GSCAN_SUBCMD_GET_SCAN_RESULTS
98+
},
99+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
100+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
101+
+ .policy = VENDOR_CMD_RAW_DATA,
102+
+#endif
103+
.doit = wl_cfgvendor_gscan_get_batch_results
104+
},
105+
{
106+
@@ -1246,6 +1273,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
107+
.subcmd = GSCAN_SUBCMD_GET_CHANNEL_LIST
108+
},
109+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
110+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
111+
+ .policy = VENDOR_CMD_RAW_DATA,
112+
+#endif
113+
.doit = wl_cfgvendor_gscan_get_channel_list
114+
},
115+
#endif /* GSCAN_SUPPORT */
116+
@@ -1256,6 +1286,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
117+
.subcmd = RTT_SUBCMD_SET_CONFIG
118+
},
119+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
120+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
121+
+ .policy = VENDOR_CMD_RAW_DATA,
122+
+#endif
123+
.doit = wl_cfgvendor_rtt_set_config
124+
},
125+
{
126+
@@ -1264,6 +1297,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
127+
.subcmd = RTT_SUBCMD_CANCEL_CONFIG
128+
},
129+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
130+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
131+
+ .policy = VENDOR_CMD_RAW_DATA,
132+
+#endif
133+
.doit = wl_cfgvendor_rtt_cancel_config
134+
},
135+
{
136+
@@ -1272,6 +1308,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
137+
.subcmd = RTT_SUBCMD_GETCAPABILITY
138+
},
139+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
140+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
141+
+ .policy = VENDOR_CMD_RAW_DATA,
142+
+#endif
143+
.doit = wl_cfgvendor_rtt_get_capability
144+
},
145+
#endif /* RTT_SUPPORT */
146+
@@ -1281,6 +1320,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
147+
.subcmd = ANDR_WIFI_SUBCMD_GET_FEATURE_SET
148+
},
149+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
150+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
151+
+ .policy = VENDOR_CMD_RAW_DATA,
152+
+#endif
153+
.doit = rtw_cfgvendor_get_feature_set
154+
},
155+
{
156+
@@ -1289,6 +1331,9 @@ static const struct wiphy_vendor_command rtw_vendor_cmds [] = {
157+
.subcmd = ANDR_WIFI_SUBCMD_GET_FEATURE_SET_MATRIX
158+
},
159+
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | WIPHY_VENDOR_CMD_NEED_NETDEV,
160+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
161+
+ .policy = VENDOR_CMD_RAW_DATA,
162+
+#endif
163+
.doit = rtw_cfgvendor_get_feature_set_matrix
164+
}
165+
};
166+
--
167+
2.26.0
168+

0 commit comments

Comments
 (0)