fix cfg80211 of 8723cs

This commit is contained in:
Martin Ayotte 2020-08-07 10:44:17 -04:00
parent e42d4c50ba
commit 2b7852c499

View File

@ -69951,7 +69951,7 @@ new file mode 100644
index 00000000..6ee63c1d
--- /dev/null
+++ b/drivers/net/wireless/realtek/rtl8723cs/core/rtw_security.c
@@ -0,0 +1,3320 @@
@@ -0,0 +1,3354 @@
+/******************************************************************************
+ *
+ * Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved.
@ -314093,6 +314093,33 @@ index 00000000..4b44a788
+ return ret;
+}
+
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 8, 0))
+
+static void
+cfg80211_rtw_update_mgmt_frame_registrations(struct wiphy *wiphy,
+ struct wireless_dev *wdev,
+ struct mgmt_frame_regs *upd)
+{
+ struct net_device *ndev = wdev_to_ndev(wdev);
+ struct rtw_wdev_priv *pwdev_priv;
+ _adapter *adapter;
+
+ if (ndev == NULL)
+ return;
+
+ adapter = (_adapter *)rtw_netdev_priv(ndev);
+ pwdev_priv = adapter_wdev_data(adapter);
+
+#ifdef CONFIG_DEBUG_CFG80211
+ RTW_INFO(FUNC_ADPT_FMT" stypes:%x\n", FUNC_ADPT_ARG(adapter),
+ upd->interface_stypes);
+#endif
+
+ /* not implemented, see bellow */
+}
+
+#else
+
+static void cfg80211_rtw_mgmt_frame_register(struct wiphy *wiphy,
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 6, 0))
+ struct wireless_dev *wdev,
@ -314137,6 +314164,8 @@ index 00000000..4b44a788
+ return;
+}
+
+#endif
+
+#if defined(CONFIG_TDLS) && (LINUX_VERSION_CODE >= KERNEL_VERSION(3,2,0))
+static int cfg80211_rtw_tdls_mgmt(struct wiphy *wiphy,
+ struct net_device *ndev,
@ -315046,7 +315075,11 @@ index 00000000..4b44a788
+
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) || defined(COMPAT_KERNEL_RELEASE)
+ .mgmt_tx = cfg80211_rtw_mgmt_tx,
+// .mgmt_frame_register = cfg80211_rtw_mgmt_frame_register,
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 8, 0))
+ .update_mgmt_frame_registrations = cfg80211_rtw_update_mgmt_frame_registrations,
+#else
+ .mgmt_frame_register = cfg80211_rtw_mgmt_frame_register,
+#endif
+#elif (LINUX_VERSION_CODE>=KERNEL_VERSION(2,6,34) && LINUX_VERSION_CODE<=KERNEL_VERSION(2,6,35))
+ .action = cfg80211_rtw_mgmt_tx,
+#endif