[openwrt/openwrt] rtl8812au-ct: fix build with newer backports cfg80211 api

LEDE Commits lede-commits at lists.infradead.org
Sun Dec 11 00:49:00 PST 2022


nbd pushed a commit to openwrt/openwrt.git, branch master:
https://git.openwrt.org/03518a1b3a565c74391ddfe0d5bfb352994141ef

commit 03518a1b3a565c74391ddfe0d5bfb352994141ef
Author: Felix Fietkau <nbd at nbd.name>
AuthorDate: Sun Dec 11 09:48:18 2022 +0100

    rtl8812au-ct: fix build with newer backports cfg80211 api
    
    Signed-off-by: Felix Fietkau <nbd at nbd.name>
---
 .../rtl8812au-ct/patches/100-api_update.patch      | 56 ++++++++++++++++++++++
 1 file changed, 56 insertions(+)

diff --git a/package/kernel/rtl8812au-ct/patches/100-api_update.patch b/package/kernel/rtl8812au-ct/patches/100-api_update.patch
new file mode 100644
index 0000000000..2c081256ed
--- /dev/null
+++ b/package/kernel/rtl8812au-ct/patches/100-api_update.patch
@@ -0,0 +1,56 @@
+--- a/os_dep/linux/ioctl_cfg80211.c
++++ b/os_dep/linux/ioctl_cfg80211.c
+@@ -798,8 +798,8 @@ check_bss:
+ 
+ 		DBG_871X(FUNC_ADPT_FMT" call cfg80211_roamed\n", FUNC_ADPT_ARG(padapter));
+ #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
+-		roam_info.channel = notify_channel;
+-		roam_info.bssid = cur_network->network.MacAddress;
++		roam_info.links[0].channel = notify_channel;
++		roam_info.links[0].bssid = cur_network->network.MacAddress;
+ 		roam_info.req_ie = pmlmepriv->assoc_req + sizeof(struct rtw_ieee80211_hdr_3addr) + 2;
+ 		roam_info.req_ie_len = pmlmepriv->assoc_req_len - sizeof(struct rtw_ieee80211_hdr_3addr) - 2;
+ 		roam_info.resp_ie = pmlmepriv->assoc_rsp + sizeof(struct rtw_ieee80211_hdr_3addr) + 6;
+@@ -1389,6 +1389,7 @@ exit:
+ 
+ static int cfg80211_rtw_add_key(struct wiphy *wiphy, struct net_device *ndev,
+ #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) || defined(COMPAT_KERNEL_RELEASE)
++                                int link_id,
+                                 u8 key_index, bool pairwise, const u8 *mac_addr,
+ #else	// (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37))
+                                 u8 key_index, const u8 *mac_addr,
+@@ -1529,6 +1530,7 @@ addkey_end:
+ 
+ static int cfg80211_rtw_get_key(struct wiphy *wiphy, struct net_device *ndev,
+ #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) || defined(COMPAT_KERNEL_RELEASE)
++                                int link_id,
+                                 u8 key_index, bool pairwise, const u8 *mac_addr,
+ #else	// (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37))
+                                 u8 key_index, const u8 *mac_addr,
+@@ -1562,6 +1564,7 @@ static int cfg80211_rtw_get_key(struct w
+ 
+ static int cfg80211_rtw_del_key(struct wiphy *wiphy, struct net_device *ndev,
+ #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) || defined(COMPAT_KERNEL_RELEASE)
++                                int link_id,
+                                 u8 key_index, bool pairwise, const u8 *mac_addr)
+ #else	// (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37))
+                                 u8 key_index, const u8 *mac_addr)
+@@ -1581,7 +1584,7 @@ static int cfg80211_rtw_del_key(struct w
+ }
+ 
+ static int cfg80211_rtw_set_default_key(struct wiphy *wiphy,
+-                                        struct net_device *ndev, u8 key_index
++                                        struct net_device *ndev, int link_id, u8 key_index
+ #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,38)) || defined(COMPAT_KERNEL_RELEASE)
+                                         , bool unicast, bool multicast
+ #endif
+@@ -4019,7 +4022,8 @@ static int cfg80211_rtw_change_beacon(st
+ 	return ret;
+ }
+ 
+-static int cfg80211_rtw_stop_ap(struct wiphy *wiphy, struct net_device *ndev)
++static int cfg80211_rtw_stop_ap(struct wiphy *wiphy, struct net_device *ndev,
++				unsigned int link_id)
+ {
+ 	DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev));
+ 	return 0;




More information about the lede-commits mailing list