Skip to content

Commit

Permalink
Squashed commit of the following:
Browse files Browse the repository at this point in the history
commit 9532d3c
Merge: 8f57287 91bc6bf
Author: Husky <1556047610@qq.com>
Date:   Mon Feb 6 09:25:43 2023 +0800

    Merge remote-tracking branch 'upstream/master'

commit 91bc6bf
Author: fishg <1423545+fishg@users.noreply.github.com>
Date:   Sun Feb 5 13:05:48 2023 +0800

    mt76x2: fix for 6.1 (coolsnowwolf#10863)

commit 60178fd
Author: Tsenghan <zhenghand@qq.com>
Date:   Sat Feb 4 21:54:27 2023 +0800

    Define domain request parameter "Line" as default (coolsnowwolf#10862)

    In Action "DescribeSubDomainRecords", define argument “Line” to the specific "defalut". This is for someone who have two or more same domain names but in different dns request source(ISP), but return more than 1 record will goto print "地址需要修改".  For document of  aliyun API, set a Line parament can solve this issue because most of users just have one ISP for each domain and its value was set as "default".

commit b597493
Author: Beginner <70857188+Beginner-Go@users.noreply.github.com>
Date:   Sat Feb 4 21:45:21 2023 +0800

    wwan/app: code alignment (coolsnowwolf#10850)

    Signed-off-by: Beginner-Go <70857188+Beginner-Go@users.noreply.github.com>

commit 1daa71c
Author: coolsnowwolf <coolsnowwolf@gmail.com>
Date:   Thu Feb 2 23:55:49 2023 +0800

    quectel_QMI_WWAN: port to linux 6.1 support

commit de25320
Author: coolsnowwolf <coolsnowwolf@gmail.com>
Date:   Thu Feb 2 19:50:19 2023 +0800

    Version update to R23.2.14

commit a8b2e68
Author: coolsnowwolf <coolsnowwolf@gmail.com>
Date:   Thu Feb 2 19:43:57 2023 +0800

    package: add wwan Quectel modem packages and luci

commit f143a15
Author: 1054009064 <44148148+1054009064@users.noreply.github.com>
Date:   Thu Feb 2 16:39:58 2023 +0800

    ipq807x: add tl-er2260t dts for other device builds in 5.15 (coolsnowwolf#10846)

    Only solves other device builds, doesn't support tl-er2260t running.

commit 27a331a
Author: coolsnowwolf <coolsnowwolf@gmail.com>
Date:   Thu Feb 2 12:46:12 2023 +0800

    autocore: fix sfp unplugged speed display

commit f6d0acb
Author: 1054009064 <44148148+1054009064@users.noreply.github.com>
Date:   Thu Feb 2 12:42:41 2023 +0800

    qca-ssdk: refresh patches (coolsnowwolf#10845)

    Fixed patch application failure.

    Fixes: 89200af ("bump qca-ssdk nss-dp and ssdk-shell, Add tplink-tl-er2260t basic support (coolsnowwolf#10777)")
    Fixes: coolsnowwolf#10844

commit 89200af
Author: qlugcp <122597754+qlugcp@users.noreply.github.com>
Date:   Thu Feb 2 01:26:55 2023 +0800

    bump qca-ssdk nss-dp and ssdk-shell, Add tplink-tl-er2260t basic support (coolsnowwolf#10777)

    * bump qca-nss-dp and ssdk ssdk-shell to 12.1

    * [qca-ssdk] delete 0008 patch as 12.1 version do not need this

    * [ipq807x]: Add support for tplink-tl-er2260t(basic)

    * remove unused parts in 2260t.dts

    * NSS:bump nss-drv64 to 12.1r2 (may affect ipq806x)

    * fix nss-dp source_url

    * qca-ssdk: refresh ssdk patch

commit 26b8595
Author: lovehackintosh <92633080+lovehackintosh@users.noreply.github.com>
Date:   Wed Feb 1 18:21:28 2023 +0800

    kernel: bump to 5.10.166, 5.15.91, 6.1.9 (coolsnowwolf#10842)

    * kernel: bump 5.15 to 5.15.91

    * kernel: bump 6.1 to 6.1.9

    * kernel: bump 5.10 to 5.10.166

commit 7fea681
Author: coolsnowwolf <coolsnowwolf@gmail.com>
Date:   Wed Feb 1 17:18:22 2023 +0800

    kernel: bump 6.1 to 6.1.9

commit 9126964
Author: coolsnowwolf <coolsnowwolf@gmail.com>
Date:   Tue Jan 31 15:06:50 2023 +0800

    rtl8812au-ac: backport linux kernel 6.1 support

commit fb0c3a7
Author: coolsnowwolf <coolsnowwolf@gmail.com>
Date:   Tue Jan 31 13:27:15 2023 +0800

    rtl8812au-ac: port RTL8812AU/21AU and RTL8814AU Wireless drivers from aircrack-ng

commit ff68c93
Author: Lollipop907 <34392880+Lollipop907@users.noreply.github.com>
Date:   Tue Jan 31 12:55:50 2023 +0800

    rockchip:fix build failure and change network for MPC1903 (coolsnowwolf#10837)

    * Update armv8.mk

    * Update 02_network

commit 0fbb5e9
Author: zfdx <47835976+zfdx123@users.noreply.github.com>
Date:   Tue Jan 31 11:40:11 2023 +0800

    ramips: hiwifi-r33: fix partition and led (coolsnowwolf#10836)

commit 8f57287
Merge: 894a107 e20fa32
Author: Husky <1556047610@qq.com>
Date:   Mon Jan 30 10:40:40 2023 +0800

    Merge remote-tracking branch 'upstream/master'

commit e20fa32
Author: 骷髅头 <74764072+DHDAXCW@users.noreply.github.com>
Date:   Sun Jan 29 19:35:47 2023 +0800

    uqmi:fix build failure (coolsnowwolf#10831)

    ERROR: package/network/utils/uqmi failed to build.

commit 7d2c157
Author: Hugo Chen <ttcf15@163.com>
Date:   Sun Jan 29 12:20:04 2023 +0800

    ci: update upload-artifact (coolsnowwolf#10824)

commit 4a50778
Author: xiaotan8 <62252056+xiaotan8@users.noreply.github.com>
Date:   Sun Jan 29 12:18:40 2023 +0800

    uqmi: bump to latest git HEAD (coolsnowwolf#10826)

commit 894a107
Merge: a35f71a fec4f5d
Author: Husky <1556047610@qq.com>
Date:   Fri Jan 27 22:37:44 2023 +0800

    Merge remote-tracking branch 'upstream/master'

commit fec4f5d
Author: Nick Hainke <vincent@systemli.org>
Date:   Mon Oct 10 08:04:41 2022 +0200

    kernel: test for kernel version greater 5.13 to fix mmc-spi

    The of_mmc_spi.o resource is provider agnostic in kernels greater 5.13
    and does not depend anymore on CONFIG_OF.

    Fixes: coolsnowwolf#10769

    Suggested-by: John Thomson <git@johnthomson.fastmail.com.au>
    Signed-off-by: Nick Hainke <vincent@systemli.org>

commit ccc6994
Author: coolsnowwolf <coolsnowwolf@gmail.com>
Date:   Thu Jan 26 21:15:53 2023 +0800

    toolchain/gcc: revert to version 11 by default
  • Loading branch information
solarflows committed Feb 6, 2023
1 parent 3b6b204 commit 1511747
Show file tree
Hide file tree
Showing 322 changed files with 93,399 additions and 915 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/openwrt-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,19 +87,19 @@ jobs:
cp -rf $(find ./bin/targets/ -type f -name "*.buildinfo" -o -name "*.manifest") ./artifact/buildinfo/
- name: Deliver buildinfo
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: OpenWrt_buildinfo
path: ./artifact/buildinfo/

- name: Deliver package
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: OpenWrt_package
path: ./artifact/package/

- name: Deliver firmware
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: OpenWrt_firmware
path: ./bin/targets/
Expand Down
4 changes: 2 additions & 2 deletions include/kernel-5.10
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
LINUX_VERSION-5.10 = .165
LINUX_KERNEL_HASH-5.10.165 = 971defc48f19ed0a2a7ffd4b48234619cac28895c985c6d747f5b707ba47af0d
LINUX_VERSION-5.10 = .166
LINUX_KERNEL_HASH-5.10.166 = 0051a1780e5bda0efc68dafab7c728b8283d2b028fedb439418f478be7d3e1af
4 changes: 2 additions & 2 deletions include/kernel-5.15
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
LINUX_VERSION-5.15 = .90
LINUX_KERNEL_HASH-5.15.90 = e6fd430022686753af7516fe7544f96aab379509dc5b7829017bdcd92b393b42
LINUX_VERSION-5.15 = .91
LINUX_KERNEL_HASH-5.15.91 = a63c2bb1beb15f1aea9c63cf80559f5b7ab58afd2da2fa5e7670c515ebe1fe80
4 changes: 2 additions & 2 deletions include/kernel-6.1
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
LINUX_VERSION-6.1 = .8
LINUX_KERNEL_HASH-6.1.8 = b60bb53ab8ba370a270454b11e93d41af29126fc72bd6ede517673e2e57b816d
LINUX_VERSION-6.1 = .9
LINUX_KERNEL_HASH-6.1.9 = d60cf185693c386e7acd9f3eb3a94ae30ffbfee0a9447a20e83711e0bdf5922b
5 changes: 3 additions & 2 deletions package/kernel/linux/modules/spi.mk
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@ define KernelPackage/mmc-spi
CONFIG_SPI=y \
CONFIG_SPI_MASTER=y
FILES:=\
$(if $(CONFIG_LINUX_5_15),$(LINUX_DIR)/drivers/mmc/host/of_mmc_spi.ko,$(if $(CONFIG_OF),$(LINUX_DIR)/drivers/mmc/host/of_mmc_spi.ko)) \
$(if $(CONFIG_OF),$(LINUX_DIR)/drivers/mmc/host/of_mmc_spi.ko@lt5.13) \
$(LINUX_DIR)/drivers/mmc/host/of_mmc_spi.ko@ge5.13 \
$(LINUX_DIR)/drivers/mmc/host/mmc_spi.ko
AUTOLOAD:=$(call AutoProbe,$(if $(CONFIG_OF),of_mmc_spi) mmc_spi)
AUTOLOAD:=$(call AutoProbe,$(if $(CONFIG_OF),of_mmc_spi@lt5.13) of_mmc_spi@ge5.13 mmc_spi)
endef

define KernelPackage/mmc-spi/description
Expand Down
2 changes: 2 additions & 0 deletions package/kernel/mac80211/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,8 @@ define Build/Prepare
$(PKG_BUILD_DIR)/backport-include/linux/bcm47xx_nvram.h

echo 'compat-wireless-$(PKG_VERSION)-$(PKG_RELEASE)-$(REVISION)' > $(PKG_BUILD_DIR)/compat_version
sed -i '/#define is_signed_type/i#ifndef is_signed_type' $(PKG_BUILD_DIR)/include/linux/overflow.h
sed -i '/#define is_signed_type/a#endif' $(PKG_BUILD_DIR)/include/linux/overflow.h
endef

ifneq ($(CONFIG_PACKAGE_kmod-cfg80211),)
Expand Down
13 changes: 13 additions & 0 deletions package/kernel/mt76/patches/091-fix-linux-6.1-build.patch
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,16 @@
mt76_dma_rx_fill(dev, &dev->q_rx[i]);
napi_enable(&dev->napi[i]);
}
--- a/mt76.h
+++ b/mt76.h
@@ -37,6 +37,9 @@
#define MT_WED_Q_TX(_n) __MT_WED_Q(MT76_WED_Q_TX, _n)
#define MT_WED_Q_RX(_n) __MT_WED_Q(MT76_WED_Q_RX, _n)
#define MT_WED_Q_TXFREE __MT_WED_Q(MT76_WED_Q_TXFREE, 0)
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(6,1,0)
+#define netif_tx_napi_add netif_napi_add_tx_weight
+#endif

struct mt76_dev;
struct mt76_phy;

67 changes: 67 additions & 0 deletions package/kernel/rtl8812au-ac/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
include $(TOPDIR)/rules.mk

PKG_NAME:=rtl8812au-ac
PKG_RELEASE:=2

PKG_LICENSE:=GPLv2
PKG_LICENSE_FILES:=

PKG_SOURCE_URL:=https://github.com/aircrack-ng/rtl8812au.git
PKG_SOURCE_PROTO:=git
PKG_SOURCE_DATE:=2023-01-23
PKG_SOURCE_VERSION:=e72dacdc4af7cf421484ce9567ef2cc995a16f3a
PKG_MIRROR_HASH:=4e2168712f62a6d736fbc3422f651c6738a37a40d226617f7d8248ad8abd2433

PKG_LICENSE:=GPL-2.0-only
PKG_LICENSE_FILES:=LICENSE
# PKG_MAINTAINER:=

PKG_BUILD_PARALLEL:=1

STAMP_CONFIGURED_DEPENDS := $(STAGING_DIR)/usr/include/mac80211-backport/backport/autoconf.h

include $(INCLUDE_DIR)/kernel.mk
include $(INCLUDE_DIR)/package.mk

define KernelPackage/rtl8812au-ac
SUBMENU:=Wireless Drivers
TITLE:=Realtek RTL8812AU/21AU wireless drivers
DEPENDS:=+kmod-cfg80211 +kmod-usb-core +@DRIVER_11AC_SUPPORT
FILES:=$(PKG_BUILD_DIR)/rtl8812au.ko
AUTOLOAD:=$(call AutoProbe,rtl8812au)
CONFLICTS:=kmod-rtl8812au-ct
endef

NOSTDINC_FLAGS:= \
$(KERNEL_NOSTDINC_FLAGS) \
-I$(PKG_BUILD_DIR) \
-I$(PKG_BUILD_DIR)/include \
-I$(STAGING_DIR)/usr/include/mac80211-backport \
-I$(STAGING_DIR)/usr/include/mac80211-backport/uapi \
-I$(STAGING_DIR)/usr/include/mac80211 \
-I$(STAGING_DIR)/usr/include/mac80211/uapi \
-include backport/autoconf.h \
-include backport/backport.h

NOSTDINC_FLAGS+= \
-DRTW_SINGLE_WIPHY \
-DRTW_USE_CFG80211_STA_EVENT \
-DCONFIG_IOCTL_CFG80211 \
-DBUILD_OPENWRT

ifeq ($(CONFIG_BIG_ENDIAN),y)
NOSTDINC_FLAGS+= -DCONFIG_BIG_ENDIAN
else
NOSTDINC_FLAGS+= -DCONFIG_LITTLE_ENDIAN
endif

define Build/Compile
+$(KERNEL_MAKE) $(PKG_JOBS) \
M="$(PKG_BUILD_DIR)" \
NOSTDINC_FLAGS="$(NOSTDINC_FLAGS)" \
CONFIG_88XXAU=m \
USER_MODULE_NAME=rtl8812au \
modules
endef

$(eval $(call KernelPackage,rtl8812au-ac))
16 changes: 16 additions & 0 deletions package/kernel/rtl8812au-ac/patches/001-use-kernel-byteorder.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
Fix compile problem when rtw_byteorder.h and asm/byteorder.h gets
included in addition for example indirectly, do not use realtek own copy
of the byteorder headers.

--- a/include/drv_types.h
+++ b/include/drv_types.h
@@ -24,7 +24,7 @@
#include <drv_conf.h>
#include <basic_types.h>
#include <osdep_service.h>
-#include <rtw_byteorder.h>
+#include <asm/byteorder.h>
#include <wlan_bssdef.h>
#include <wifi.h>
#include <ieee80211.h>

Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
--- a/Makefile
+++ b/Makefile
@@ -98,7 +98,7 @@ CONFIG_RTW_SDIO_PM_KEEP_POWER = y
###################### MP HW TX MODE FOR VHT #######################
CONFIG_MP_VHT_HW_TX_MODE = n
###################### Platform Related #######################
-CONFIG_PLATFORM_I386_PC = y
+CONFIG_PLATFORM_I386_PC = n
CONFIG_PLATFORM_ANDROID_ARM64 = n
CONFIG_PLATFORM_ARM_RPI = n
CONFIG_PLATFORM_ARM64_RPI = n
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
--- a/os_dep/linux/os_intfs.c
+++ b/os_dep/linux/os_intfs.c
@@ -254,7 +254,7 @@ int rtw_bfee_rf_number = 0; /*BeamformeeCapRfNum Rf path number, 0 for auto, ot
#endif /* CONFIG_80211N_HT */

#ifdef CONFIG_80211AC_VHT
-int rtw_vht_enable = 1; /* 0:disable, 1:enable, 2:force auto enable */
+int rtw_vht_enable = 2; /* 0:disable, 1:enable, 2:force auto enable */
module_param(rtw_vht_enable, int, 0644);

int rtw_ampdu_factor = 7;
@@ -324,7 +324,7 @@ int rtw_drv_ant_band_switch = 1; /* 0:OFF , 1:ON, Driver control antenna band sw
int rtw_single_ant_path; /*0:main ant , 1:aux ant , Fixed single antenna path, default main ant*/

/* 0: doesn't switch, 1: switch from usb2.0 to usb 3.0 2: switch from usb3.0 to usb 2.0 */
-int rtw_switch_usb_mode = 0;
+int rtw_switch_usb_mode = 1;

#ifdef CONFIG_USB_AUTOSUSPEND
int rtw_enusbss = 1;/* 0:disable,1:enable */
--
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
--- a/os_dep/linux/os_intfs.c
+++ b/os_dep/linux/os_intfs.c
@@ -2807,6 +2807,7 @@ static int netdev_vir_if_close(struct ne
{
_adapter *padapter = (_adapter *)rtw_netdev_priv(pnetdev);
struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
+ struct wireless_dev *wdev = padapter->rtw_wdev;

RTW_INFO(FUNC_NDEV_FMT" , bup=%d\n", FUNC_NDEV_ARG(pnetdev), padapter->bup);
padapter->net_closed = _TRUE;
123 changes: 123 additions & 0 deletions package/kernel/rtl8812au-ac/patches/040-wireless-5.8.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
--- a/os_dep/linux/ioctl_cfg80211.c
+++ b/os_dep/linux/ioctl_cfg80211.c
@@ -460,9 +460,9 @@ u8 rtw_cfg80211_ch_switch_notify(_adapte

#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0))
if (started) {
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0) || defined(BUILD_OPENWRT))
cfg80211_ch_switch_started_notify(adapter->pnetdev, &chdef, 0, 0, false);
-#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 11, 0))
+#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 11, 0) || defined(BUILD_OPENWRT))
cfg80211_ch_switch_started_notify(adapter->pnetdev, &chdef, 0, false);
#else
cfg80211_ch_switch_started_notify(adapter->pnetdev, &chdef, 0);
@@ -474,7 +474,7 @@ u8 rtw_cfg80211_ch_switch_notify(_adapte
if (!rtw_cfg80211_allow_ch_switch_notify(adapter))
goto exit;

-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 19, 2))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 19, 2) || defined(BUILD_OPENWRT))
cfg80211_ch_switch_notify(adapter->pnetdev, &chdef, 0);
#else
cfg80211_ch_switch_notify(adapter->pnetdev, &chdef);
@@ -1151,7 +1151,7 @@ check_bss:
#endif

#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 0, 0))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 0, 0) || defined(BUILD_OPENWRT))
roam_info.links[0].bssid = cur_network->network.MacAddress;
#else
roam_info.bssid = cur_network->network.MacAddress;
@@ -1721,7 +1721,7 @@ exit:
}

static int cfg80211_rtw_add_key(struct wiphy *wiphy, struct net_device *ndev
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0) || defined(BUILD_OPENWRT))
, int link_id
#endif
, u8 key_index
@@ -1868,7 +1868,7 @@ addkey_end:
}

static int cfg80211_rtw_get_key(struct wiphy *wiphy, struct net_device *ndev
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0) || defined(BUILD_OPENWRT))
, int link_id
#endif
, u8 keyid
@@ -2036,7 +2036,7 @@ exit:
}

static int cfg80211_rtw_del_key(struct wiphy *wiphy, struct net_device *ndev,
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0) || defined(BUILD_OPENWRT))
int link_id,
#endif
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 37)) || defined(COMPAT_KERNEL_RELEASE)
@@ -2060,7 +2060,7 @@ static int cfg80211_rtw_del_key(struct w

static int cfg80211_rtw_set_default_key(struct wiphy *wiphy,
struct net_device *ndev,
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0) || defined(BUILD_OPENWRT))
int link_id,
#endif
u8 key_index
@@ -2112,7 +2112,7 @@ static int cfg80211_rtw_set_default_key(
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 30))
int cfg80211_rtw_set_default_mgmt_key(struct wiphy *wiphy,
struct net_device *ndev,
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0) || defined(BUILD_OPENWRT))
int link_id,
#endif
u8 key_index)
@@ -5248,7 +5248,7 @@ static int cfg80211_rtw_change_beacon(st
return ret;
}

-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 19, 2))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 19, 2) || defined(BUILD_OPENWRT))
static int cfg80211_rtw_stop_ap(struct wiphy *wiphy, struct net_device *ndev, unsigned int link_id)
#else
static int cfg80211_rtw_stop_ap(struct wiphy *wiphy, struct net_device *ndev)
@@ -6125,7 +6125,7 @@ static int cfg80211_rtw_set_channel(stru
return 0;
}

-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 19, 2))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 19, 2) || defined(BUILD_OPENWRT))
static int cfg80211_rtw_get_channel(struct wiphy *wiphy, struct wireless_dev *wdev, unsigned int link_id, struct cfg80211_chan_def *chandef){
#else
static int cfg80211_rtw_get_channel(struct wiphy *wiphy, struct wireless_dev *wdev, struct cfg80211_chan_def *chandef){
@@ -10434,9 +10434,9 @@ void rtw_wdev_unregister(struct wireless
rtw_cfg80211_indicate_scan_done(adapter, _TRUE);

#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 11, 0)) || defined(COMPAT_KERNEL_RELEASE)
- #if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 0, 0))
+ #if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 0, 0) || defined(BUILD_OPENWRT))
if (wdev->links[0].client.current_bss) {
- #elif (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 19, 2))
+ #elif (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 19, 2) || defined(BUILD_OPENWRT))
if (wdev->connected) {
#else
if (wdev->current_bss) {
--- a/os_dep/linux/os_intfs.c
+++ b/os_dep/linux/os_intfs.c
@@ -2823,7 +2823,13 @@ static int netdev_vir_if_close(struct ne

#ifdef CONFIG_IOCTL_CFG80211
wdev->iftype = NL80211_IFTYPE_MONITOR;
+ #if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 0, 0) || defined(BUILD_OPENWRT))
+ wdev->links[0].client.current_bss = NULL;
+ #elif (LINUX_VERSION_CODE >= KERNEL_VERSION(5,19, 2))
+ wdev->connected = NULL;
+ #else
wdev->current_bss = NULL;
+ #endif
rtw_scan_abort(padapter);
rtw_cfg80211_wait_scan_req_empty(padapter, 200);
adapter_wdev_data(padapter)->bandroid_scan = _FALSE;
Loading

0 comments on commit 1511747

Please sign in to comment.