forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-05-13 9d77db3c730780c8ef5ccd4b66403ff5675cfe4e
kernel/drivers/net/wireless/rockchip_wlan/rkwifi/bcmdhd/wl_android_ext.h
old mode 100644new mode 100755
....@@ -1,4 +1,3 @@
1
-/* SPDX-License-Identifier: GPL-2.0 */
21
32 #ifndef _wl_android_ext_
43 #define _wl_android_ext_
....@@ -48,10 +47,9 @@
4847 int wl_ext_iovar_setbuf_bsscfg(struct net_device *dev, s8 *iovar_name,
4948 void *param, s32 paramlen, void *buf, s32 buflen, s32 bsscfg_idx,
5049 struct mutex* buf_sync);
51
-chanspec_t wl_ext_chspec_driver_to_host(struct dhd_pub *dhd, chanspec_t chanspec);
52
-chanspec_t wl_ext_chspec_host_to_driver(struct dhd_pub *dhd, chanspec_t chanspec);
50
+chanspec_t wl_ext_chspec_driver_to_host(int ioctl_ver, chanspec_t chanspec);
51
+chanspec_t wl_ext_chspec_host_to_driver(int ioctl_ver, chanspec_t chanspec);
5352 bool wl_ext_dfs_chan(struct wl_chan_info *chan_info);
54
-bool wl_ext_passive_chan(struct net_device *dev, struct wl_chan_info *chan_info);
5553 uint16 wl_ext_get_default_chan(struct net_device *dev,
5654 uint16 *chan_2g, uint16 *chan_5g, bool nodfs);
5755 int wl_ext_set_chanspec(struct net_device *dev, struct wl_chan_info *chan_info,
....@@ -60,6 +58,11 @@
6058 #endif
6159 #if defined(WL_CFG80211) || defined(WL_ESCAN)
6260 void wl_ext_user_sync(struct dhd_pub *dhd, int ifidx, bool lock);
61
+#endif
62
+#if defined(WL_CFG80211)
63
+bool wl_legacy_chip_check(struct net_device *net);
64
+bool wl_new_chip_check(struct net_device *net);
65
+bool wl_extsae_chip(struct dhd_pub *dhd);
6366 #endif
6467 #if defined(WL_EXT_IAPSTA) || defined(WL_CFG80211)
6568 void wl_ext_bss_iovar_war(struct net_device *dev, s32 *val);
....@@ -175,16 +178,16 @@
175178 #else
176179 wl_scan_results_v109_t *bss_list,
177180 #endif
178
- int *best_2g_ch, int *best_5g_ch, int *best_6g_ch
181
+ int ioctl_ver, int *best_2g_ch, int *best_5g_ch, int *best_6g_ch
179182 );
180183
181184 #ifdef WL_6G_BAND
182
-#define CHSPEC2BANDSTR(chspec) ((chspec && CHSPEC_IS2G(chspec)) ? "2g" : CHSPEC_IS5G(chspec) ? \
185
+#define CHSPEC2BANDSTR(chspec) (CHSPEC_IS2G(chspec) ? "2g" : CHSPEC_IS5G(chspec) ? \
183186 "5g" : CHSPEC_IS6G(chspec) ? "6g" : "0g")
184187 #define WLCBAND2STR(band) ((band == WLC_BAND_2G) ? "2g" : (band == WLC_BAND_5G) ? \
185188 "5g" : (band == WLC_BAND_6G) ? "6g" : "0g")
186189 #else
187
-#define CHSPEC2BANDSTR(chspec) ((chspec && CHSPEC_IS2G(chspec)) ? "2g" : CHSPEC_IS5G(chspec) ? \
190
+#define CHSPEC2BANDSTR(chspec) (CHSPEC_IS2G(chspec) ? "2g" : CHSPEC_IS5G(chspec) ? \
188191 "5g" : "0g")
189192 #define WLCBAND2STR(band) ((band == WLC_BAND_2G) ? "2g" : (band == WLC_BAND_5G) ? \
190193 "5g" : "0g")