From c79ffb68395e85ecdab7a8e6feff915d31fd6aec Mon Sep 17 00:00:00 2001 From: Tianling Shen Date: Fri, 12 Jul 2024 13:07:27 +0800 Subject: [PATCH] mac80211: refresh patches Signed-off-by: Tianling Shen --- ...isable-caldata-prefetch-for-sdio-bus.patch | 4 +- .../ath10k/983-ath10k-allow-vht-on-2g.patch | 2 +- ...k-always-use-mac80211-loss-detection.patch | 2 +- .../ath11k/983-ath11k-Enable-VHT-for-2G.patch | 4 +- ...-enable-BT-device-recovery-mechanism.patch | 4 +- ...-print-firmware-type-in-info-message.patch | 6 +- ...rtw_fw_beacon_filter_config-with-rtw.patch | 2 +- .../rtl/005-wifi-rtw88-Drop-rf_lock.patch | 4 +- .../rtl/006-wifi-rtw88-Drop-h2c.lock.patch | 4 +- .../rtl/007-wifi-rtw88-Drop-coex-mutex.patch | 6 +- ...fi-rtw88-Add-common-USB-chip-support.patch | 6 +- ...ackports-rtw88-21cu-22cu-22bu-8723du.patch | 4 +- ...on-atomic-sta-iterator-in-rtw_ra_mas.patch | 4 +- ...dd-SDIO-HCI-support-in-the-TX-page-t.patch | 4 +- ...eturn-the-original-error-from-rtw_pw.patch | 30 ---- ...eturn-the-original-error-from-rtw_ma.patch | 41 ----- ...Add-the-cpwm-rpwm-_addr-for-SDIO-bas.patch | 2 +- ...Reserve-8-bytes-of-extra-TX-headroom.patch | 2 +- ...add-bitmap-for-dynamic-port-settings.patch | 14 +- ...fi-rtw88-add-port-switch-for-AP-mode.patch | 8 +- ...88-8822c-extend-reserved-page-number.patch | 2 +- ...ifi-rtw88-disallow-PS-during-AP-mode.patch | 6 +- ...efine-reserved-page-flow-for-AP-mode.patch | 2 +- ...8-prevent-scan-abort-with-other-VIFs.patch | 6 +- ...e-station-mode-concurrent-scan-with-.patch | 12 +- ...fi-rtw88-8822c-add-iface-combination.patch | 2 +- ...-rtw8821c-Fix-rfe_option-field-width.patch | 9 -- ...kg_type-correctly-for-specific-rtw88.patch | 6 +- ...rtw8821c_switch_rf_set-according-to-.patch | 2 +- ...wifi-rtw88-Update-spelling-in-main.h.patch | 4 +- ...k-on-error-path-in-rtw_ops_add_inter.patch | 2 +- ...ork-to-update-rate-to-avoid-RCU-warn.patch | 132 ---------------- ...ct-PS-calculation-for-SUPPORTS_DYNAM.patch | 145 ------------------ ...fi-rtw88-Stop-high-queue-during-scan.patch | 2 +- ...-not-entering-PS-mode-after-AP-stops.patch | 6 +- .../subsys/600-mac80211-allow-vht-on-2g.patch | 4 +- 36 files changed, 69 insertions(+), 426 deletions(-) delete mode 100644 package/kernel/mac80211/patches/rtl/021-59-wifi-rtw88-mac-Return-the-original-error-from-rtw_pw.patch delete mode 100644 package/kernel/mac80211/patches/rtl/021-60-wifi-rtw88-mac-Return-the-original-error-from-rtw_ma.patch delete mode 100644 package/kernel/mac80211/patches/rtl/049-wifi-rtw88-use-work-to-update-rate-to-avoid-RCU-warn.patch delete mode 100644 package/kernel/mac80211/patches/rtl/056-wifi-rtw88-correct-PS-calculation-for-SUPPORTS_DYNAM.patch diff --git a/package/kernel/mac80211/patches/ath10k/982-ath10k-disable-caldata-prefetch-for-sdio-bus.patch b/package/kernel/mac80211/patches/ath10k/982-ath10k-disable-caldata-prefetch-for-sdio-bus.patch index f9d28a2245..7a044775b1 100644 --- a/package/kernel/mac80211/patches/ath10k/982-ath10k-disable-caldata-prefetch-for-sdio-bus.patch +++ b/package/kernel/mac80211/patches/ath10k/982-ath10k-disable-caldata-prefetch-for-sdio-bus.patch @@ -1,6 +1,6 @@ --- a/drivers/net/wireless/ath/ath10k/core.c +++ b/drivers/net/wireless/ath/ath10k/core.c -@@ -3534,7 +3534,8 @@ int ath10k_core_register(struct ath10k * +@@ -3537,7 +3537,8 @@ int ath10k_core_register(struct ath10k * * Forcing the work to be done immediately works around this problem * but may also delay the boot when firmware images cannot be found. */ @@ -12,7 +12,7 @@ } --- a/drivers/net/wireless/ath/ath10k/debug.c +++ b/drivers/net/wireless/ath/ath10k/debug.c -@@ -1261,6 +1261,9 @@ static int ath10k_debug_cal_data_fetch(s +@@ -1260,6 +1260,9 @@ static int ath10k_debug_cal_data_fetch(s if (ar->hw_params.cal_data_len == 0) return -EOPNOTSUPP; diff --git a/package/kernel/mac80211/patches/ath10k/983-ath10k-allow-vht-on-2g.patch b/package/kernel/mac80211/patches/ath10k/983-ath10k-allow-vht-on-2g.patch index 3fb26bff90..33b3d2ef2c 100644 --- a/package/kernel/mac80211/patches/ath10k/983-ath10k-allow-vht-on-2g.patch +++ b/package/kernel/mac80211/patches/ath10k/983-ath10k-allow-vht-on-2g.patch @@ -1,6 +1,6 @@ --- a/drivers/net/wireless/ath/ath10k/mac.c +++ b/drivers/net/wireless/ath/ath10k/mac.c -@@ -5034,6 +5034,7 @@ static void ath10k_mac_setup_ht_vht_cap( +@@ -5036,6 +5036,7 @@ static void ath10k_mac_setup_ht_vht_cap( if (ar->phy_capability & WHAL_WLAN_11G_CAPABILITY) { band = &ar->mac.sbands[NL80211_BAND_2GHZ]; band->ht_cap = ht_cap; diff --git a/package/kernel/mac80211/patches/ath10k/988-ath10k-always-use-mac80211-loss-detection.patch b/package/kernel/mac80211/patches/ath10k/988-ath10k-always-use-mac80211-loss-detection.patch index b9cdae7e1f..d14f25104e 100644 --- a/package/kernel/mac80211/patches/ath10k/988-ath10k-always-use-mac80211-loss-detection.patch +++ b/package/kernel/mac80211/patches/ath10k/988-ath10k-always-use-mac80211-loss-detection.patch @@ -18,7 +18,7 @@ Signed-off-by: David Bauer --- a/drivers/net/wireless/ath/ath10k/mac.c +++ b/drivers/net/wireless/ath/ath10k/mac.c -@@ -10089,7 +10089,6 @@ int ath10k_mac_register(struct ath10k *a +@@ -10090,7 +10090,6 @@ int ath10k_mac_register(struct ath10k *a ieee80211_hw_set(ar->hw, CHANCTX_STA_CSA); ieee80211_hw_set(ar->hw, QUEUE_CONTROL); ieee80211_hw_set(ar->hw, SUPPORTS_TX_FRAG); diff --git a/package/kernel/mac80211/patches/ath11k/983-ath11k-Enable-VHT-for-2G.patch b/package/kernel/mac80211/patches/ath11k/983-ath11k-Enable-VHT-for-2G.patch index b2c21617a2..32d7773144 100644 --- a/package/kernel/mac80211/patches/ath11k/983-ath11k-Enable-VHT-for-2G.patch +++ b/package/kernel/mac80211/patches/ath11k/983-ath11k-Enable-VHT-for-2G.patch @@ -1,6 +1,6 @@ --- a/drivers/net/wireless/ath/ath11k/mac.c +++ b/drivers/net/wireless/ath/ath11k/mac.c -@@ -2777,9 +2777,9 @@ static void ath11k_peer_assoc_h_phymode( +@@ -2773,9 +2773,9 @@ static void ath11k_peer_assoc_h_phymode( } else if (sta->deflink.vht_cap.vht_supported && !ath11k_peer_assoc_h_vht_masked(vht_mcs_mask)) { if (sta->deflink.bandwidth == IEEE80211_STA_RX_BW_40) @@ -12,7 +12,7 @@ } else if (sta->deflink.ht_cap.ht_supported && !ath11k_peer_assoc_h_ht_masked(ht_mcs_mask)) { if (sta->deflink.bandwidth == IEEE80211_STA_RX_BW_40) -@@ -5615,6 +5615,9 @@ static void ath11k_mac_setup_ht_vht_cap( +@@ -5613,6 +5613,9 @@ static void ath11k_mac_setup_ht_vht_cap( *ht_cap_info = ht_cap; band->ht_cap = ath11k_create_ht_cap(ar, ht_cap, rate_cap_rx_chainmask); diff --git a/package/kernel/mac80211/patches/rtl/002-wifi-rtw88-8821c-enable-BT-device-recovery-mechanism.patch b/package/kernel/mac80211/patches/rtl/002-wifi-rtw88-8821c-enable-BT-device-recovery-mechanism.patch index 9149e989d5..d0a07c4824 100644 --- a/package/kernel/mac80211/patches/rtl/002-wifi-rtw88-8821c-enable-BT-device-recovery-mechanism.patch +++ b/package/kernel/mac80211/patches/rtl/002-wifi-rtw88-8821c-enable-BT-device-recovery-mechanism.patch @@ -66,7 +66,7 @@ Link: https://lore.kernel.org/r/20221128075653.5221-1-pkshih@realtek.com void rtw_fw_channel_switch(struct rtw_dev *rtwdev, bool enable); --- a/drivers/net/wireless/realtek/rtw88/mac.c +++ b/drivers/net/wireless/realtek/rtw88/mac.c -@@ -916,7 +916,8 @@ out: +@@ -918,7 +918,8 @@ out: return ret; } @@ -76,7 +76,7 @@ Link: https://lore.kernel.org/r/20221128075653.5221-1-pkshih@realtek.com { if (rtw_chip_wcpu_11n(rtwdev)) return __rtw_download_firmware_legacy(rtwdev, fw); -@@ -924,6 +925,21 @@ int rtw_download_firmware(struct rtw_dev +@@ -926,6 +927,21 @@ int rtw_download_firmware(struct rtw_dev return __rtw_download_firmware(rtwdev, fw); } diff --git a/package/kernel/mac80211/patches/rtl/003-wifi-rtw88-print-firmware-type-in-info-message.patch b/package/kernel/mac80211/patches/rtl/003-wifi-rtw88-print-firmware-type-in-info-message.patch index 2bc94f3536..8037b10a3a 100644 --- a/package/kernel/mac80211/patches/rtl/003-wifi-rtw88-print-firmware-type-in-info-message.patch +++ b/package/kernel/mac80211/patches/rtl/003-wifi-rtw88-print-firmware-type-in-info-message.patch @@ -26,7 +26,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-2-s.hauer@pengutronix.de --- a/drivers/net/wireless/realtek/rtw88/main.c +++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -1731,7 +1731,8 @@ static void rtw_load_firmware_cb(const s +@@ -1746,7 +1746,8 @@ static void rtw_load_firmware_cb(const s update_firmware_info(rtwdev, fw); complete_all(&fw->completion); @@ -36,7 +36,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-2-s.hauer@pengutronix.de fw->version, fw->sub_version, fw->sub_index, fw->h2c_version); } -@@ -1757,6 +1758,7 @@ static int rtw_load_firmware(struct rtw_ +@@ -1772,6 +1773,7 @@ static int rtw_load_firmware(struct rtw_ return -ENOENT; } @@ -46,7 +46,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-2-s.hauer@pengutronix.de --- a/drivers/net/wireless/realtek/rtw88/main.h +++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -1851,6 +1851,7 @@ struct rtw_fw_state { +@@ -1854,6 +1854,7 @@ struct rtw_fw_state { u16 h2c_version; u32 feature; u32 feature_ext; diff --git a/package/kernel/mac80211/patches/rtl/004-wifi-rtw88-Call-rtw_fw_beacon_filter_config-with-rtw.patch b/package/kernel/mac80211/patches/rtl/004-wifi-rtw88-Call-rtw_fw_beacon_filter_config-with-rtw.patch index cb78356f74..7810d910f3 100644 --- a/package/kernel/mac80211/patches/rtl/004-wifi-rtw88-Call-rtw_fw_beacon_filter_config-with-rtw.patch +++ b/package/kernel/mac80211/patches/rtl/004-wifi-rtw88-Call-rtw_fw_beacon_filter_config-with-rtw.patch @@ -18,7 +18,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-3-s.hauer@pengutronix.de --- a/drivers/net/wireless/realtek/rtw88/mac80211.c +++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -487,8 +487,8 @@ static int rtw_ops_sta_remove(struct iee +@@ -483,8 +483,8 @@ static int rtw_ops_sta_remove(struct iee { struct rtw_dev *rtwdev = hw->priv; diff --git a/package/kernel/mac80211/patches/rtl/005-wifi-rtw88-Drop-rf_lock.patch b/package/kernel/mac80211/patches/rtl/005-wifi-rtw88-Drop-rf_lock.patch index 2c0ffd8f2b..81919881f9 100644 --- a/package/kernel/mac80211/patches/rtl/005-wifi-rtw88-Drop-rf_lock.patch +++ b/package/kernel/mac80211/patches/rtl/005-wifi-rtw88-Drop-rf_lock.patch @@ -110,7 +110,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-4-s.hauer@pengutronix.de static inline u32 --- a/drivers/net/wireless/realtek/rtw88/main.c +++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -2067,7 +2067,6 @@ int rtw_core_init(struct rtw_dev *rtwdev +@@ -2080,7 +2080,6 @@ int rtw_core_init(struct rtw_dev *rtwdev skb_queue_head_init(&rtwdev->coex.queue); skb_queue_head_init(&rtwdev->tx_report.queue); @@ -120,7 +120,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-4-s.hauer@pengutronix.de spin_lock_init(&rtwdev->tx_report.q_lock); --- a/drivers/net/wireless/realtek/rtw88/main.h +++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -1995,9 +1995,6 @@ struct rtw_dev { +@@ -1998,9 +1998,6 @@ struct rtw_dev { /* ensures exclusive access from mac80211 callbacks */ struct mutex mutex; diff --git a/package/kernel/mac80211/patches/rtl/006-wifi-rtw88-Drop-h2c.lock.patch b/package/kernel/mac80211/patches/rtl/006-wifi-rtw88-Drop-h2c.lock.patch index 9363596c09..08a7b779bb 100644 --- a/package/kernel/mac80211/patches/rtl/006-wifi-rtw88-Drop-h2c.lock.patch +++ b/package/kernel/mac80211/patches/rtl/006-wifi-rtw88-Drop-h2c.lock.patch @@ -89,7 +89,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-5-s.hauer@pengutronix.de void --- a/drivers/net/wireless/realtek/rtw88/main.c +++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -2067,7 +2067,6 @@ int rtw_core_init(struct rtw_dev *rtwdev +@@ -2080,7 +2080,6 @@ int rtw_core_init(struct rtw_dev *rtwdev skb_queue_head_init(&rtwdev->coex.queue); skb_queue_head_init(&rtwdev->tx_report.queue); @@ -99,7 +99,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-5-s.hauer@pengutronix.de --- a/drivers/net/wireless/realtek/rtw88/main.h +++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -2020,8 +2020,6 @@ struct rtw_dev { +@@ -2023,8 +2023,6 @@ struct rtw_dev { struct { /* incicate the mail box to use with fw */ u8 last_box_num; diff --git a/package/kernel/mac80211/patches/rtl/007-wifi-rtw88-Drop-coex-mutex.patch b/package/kernel/mac80211/patches/rtl/007-wifi-rtw88-Drop-coex-mutex.patch index f2bdaaf20b..edfa3be359 100644 --- a/package/kernel/mac80211/patches/rtl/007-wifi-rtw88-Drop-coex-mutex.patch +++ b/package/kernel/mac80211/patches/rtl/007-wifi-rtw88-Drop-coex-mutex.patch @@ -52,7 +52,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-6-s.hauer@pengutronix.de } --- a/drivers/net/wireless/realtek/rtw88/main.c +++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -2071,7 +2071,6 @@ int rtw_core_init(struct rtw_dev *rtwdev +@@ -2084,7 +2084,6 @@ int rtw_core_init(struct rtw_dev *rtwdev spin_lock_init(&rtwdev->tx_report.q_lock); mutex_init(&rtwdev->mutex); @@ -60,7 +60,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-6-s.hauer@pengutronix.de mutex_init(&rtwdev->hal.tx_power_mutex); init_waitqueue_head(&rtwdev->coex.wait); -@@ -2143,7 +2142,6 @@ void rtw_core_deinit(struct rtw_dev *rtw +@@ -2156,7 +2155,6 @@ void rtw_core_deinit(struct rtw_dev *rtw } mutex_destroy(&rtwdev->mutex); @@ -70,7 +70,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-6-s.hauer@pengutronix.de EXPORT_SYMBOL(rtw_core_deinit); --- a/drivers/net/wireless/realtek/rtw88/main.h +++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -1501,8 +1501,6 @@ struct rtw_coex_stat { +@@ -1504,8 +1504,6 @@ struct rtw_coex_stat { }; struct rtw_coex { diff --git a/package/kernel/mac80211/patches/rtl/009-wifi-rtw88-Add-common-USB-chip-support.patch b/package/kernel/mac80211/patches/rtl/009-wifi-rtw88-Add-common-USB-chip-support.patch index 0f59424827..4950754978 100644 --- a/package/kernel/mac80211/patches/rtl/009-wifi-rtw88-Add-common-USB-chip-support.patch +++ b/package/kernel/mac80211/patches/rtl/009-wifi-rtw88-Add-common-USB-chip-support.patch @@ -50,7 +50,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-8-s.hauer@pengutronix.de +rtw88_usb-objs := usb.o --- a/drivers/net/wireless/realtek/rtw88/mac.c +++ b/drivers/net/wireless/realtek/rtw88/mac.c -@@ -1058,6 +1058,9 @@ static int txdma_queue_mapping(struct rt +@@ -1060,6 +1060,9 @@ static int txdma_queue_mapping(struct rt if (rtw_chip_wcpu_11ac(rtwdev)) rtw_write32(rtwdev, REG_H2CQ_CSR, BIT_H2CQ_FULL); @@ -62,7 +62,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-8-s.hauer@pengutronix.de --- a/drivers/net/wireless/realtek/rtw88/main.c +++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -1783,6 +1783,10 @@ static int rtw_chip_parameter_setup(stru +@@ -1798,6 +1798,10 @@ static int rtw_chip_parameter_setup(stru rtwdev->hci.rpwm_addr = 0x03d9; rtwdev->hci.cpwm_addr = 0x03da; break; @@ -75,7 +75,7 @@ Link: https://lore.kernel.org/r/20221202081224.2779981-8-s.hauer@pengutronix.de return -EINVAL; --- a/drivers/net/wireless/realtek/rtw88/main.h +++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -871,6 +871,10 @@ struct rtw_chip_ops { +@@ -874,6 +874,10 @@ struct rtw_chip_ops { bool is_tx2_path); void (*config_txrx_mode)(struct rtw_dev *rtwdev, u8 tx_path, u8 rx_path, bool is_tx2_path); diff --git a/package/kernel/mac80211/patches/rtl/014-backports-rtw88-21cu-22cu-22bu-8723du.patch b/package/kernel/mac80211/patches/rtl/014-backports-rtw88-21cu-22cu-22bu-8723du.patch index d453f05adc..cf218e5004 100644 --- a/package/kernel/mac80211/patches/rtl/014-backports-rtw88-21cu-22cu-22bu-8723du.patch +++ b/package/kernel/mac80211/patches/rtl/014-backports-rtw88-21cu-22cu-22bu-8723du.patch @@ -1,6 +1,6 @@ --- a/Kconfig.local +++ b/Kconfig.local -@@ -1135,15 +1135,30 @@ config BACKPORTED_RTW88_CORE +@@ -1111,15 +1111,30 @@ config BACKPORTED_RTW88_CORE config BACKPORTED_RTW88_PCI tristate default RTW88_PCI @@ -49,7 +49,7 @@ CPTCFG_SSB_PCMCIAHOST=y --- a/local-symbols +++ b/local-symbols -@@ -375,13 +375,18 @@ RTL8XXXU_UNTESTED= +@@ -367,13 +367,18 @@ RTL8XXXU_UNTESTED= RTW88= RTW88_CORE= RTW88_PCI= diff --git a/package/kernel/mac80211/patches/rtl/017-wifi-rtw88-Use-non-atomic-sta-iterator-in-rtw_ra_mas.patch b/package/kernel/mac80211/patches/rtl/017-wifi-rtw88-Use-non-atomic-sta-iterator-in-rtw_ra_mas.patch index 240742382f..36a6c42823 100644 --- a/package/kernel/mac80211/patches/rtl/017-wifi-rtw88-Use-non-atomic-sta-iterator-in-rtw_ra_mas.patch +++ b/package/kernel/mac80211/patches/rtl/017-wifi-rtw88-Use-non-atomic-sta-iterator-in-rtw_ra_mas.patch @@ -26,7 +26,7 @@ Link: https://lore.kernel.org/r/20230108211324.442823-4-martin.blumenstingl@goog --- a/drivers/net/wireless/realtek/rtw88/mac80211.c +++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -737,7 +737,7 @@ static void rtw_ra_mask_info_update(stru +@@ -733,7 +733,7 @@ static void rtw_ra_mask_info_update(stru br_data.rtwdev = rtwdev; br_data.vif = vif; br_data.mask = mask; @@ -35,7 +35,7 @@ Link: https://lore.kernel.org/r/20230108211324.442823-4-martin.blumenstingl@goog } static int rtw_ops_set_bitrate_mask(struct ieee80211_hw *hw, -@@ -746,7 +746,9 @@ static int rtw_ops_set_bitrate_mask(stru +@@ -742,7 +742,9 @@ static int rtw_ops_set_bitrate_mask(stru { struct rtw_dev *rtwdev = hw->priv; diff --git a/package/kernel/mac80211/patches/rtl/021-55-wifi-rtw88-mac-Add-SDIO-HCI-support-in-the-TX-page-t.patch b/package/kernel/mac80211/patches/rtl/021-55-wifi-rtw88-mac-Add-SDIO-HCI-support-in-the-TX-page-t.patch index 074fcdc826..54bdb53d57 100644 --- a/package/kernel/mac80211/patches/rtl/021-55-wifi-rtw88-mac-Add-SDIO-HCI-support-in-the-TX-page-t.patch +++ b/package/kernel/mac80211/patches/rtl/021-55-wifi-rtw88-mac-Add-SDIO-HCI-support-in-the-TX-page-t.patch @@ -18,7 +18,7 @@ Link: https://lore.kernel.org/r/20230218152944.48842-3-martin.blumenstingl@googl --- a/drivers/net/wireless/realtek/rtw88/mac.c +++ b/drivers/net/wireless/realtek/rtw88/mac.c -@@ -1043,6 +1043,9 @@ static int txdma_queue_mapping(struct rt +@@ -1045,6 +1045,9 @@ static int txdma_queue_mapping(struct rt else return -EINVAL; break; @@ -28,7 +28,7 @@ Link: https://lore.kernel.org/r/20230218152944.48842-3-martin.blumenstingl@googl default: return -EINVAL; } -@@ -1205,6 +1208,9 @@ static int priority_queue_cfg(struct rtw +@@ -1207,6 +1210,9 @@ static int priority_queue_cfg(struct rtw else return -EINVAL; break; diff --git a/package/kernel/mac80211/patches/rtl/021-59-wifi-rtw88-mac-Return-the-original-error-from-rtw_pw.patch b/package/kernel/mac80211/patches/rtl/021-59-wifi-rtw88-mac-Return-the-original-error-from-rtw_pw.patch deleted file mode 100644 index 6417ea8ef5..0000000000 --- a/package/kernel/mac80211/patches/rtl/021-59-wifi-rtw88-mac-Return-the-original-error-from-rtw_pw.patch +++ /dev/null @@ -1,30 +0,0 @@ -From b7ed9fa2cb76ca7a3c3cd4a6d35748fe1fbda9f6 Mon Sep 17 00:00:00 2001 -From: Martin Blumenstingl -Date: Sun, 26 Feb 2023 23:10:03 +0100 -Subject: [PATCH 59/85] wifi: rtw88: mac: Return the original error from - rtw_pwr_seq_parser() - -rtw_pwr_seq_parser() calls rtw_sub_pwr_seq_parser() which can either -return -EBUSY, -EINVAL or 0. Propagate the original error code instead -of unconditionally returning -EBUSY in case of an error. - -Fixes: e3037485c68e ("rtw88: new Realtek 802.11ac driver") -Signed-off-by: Martin Blumenstingl -Reviewed-by: Ping-Ke Shih -Signed-off-by: Kalle Valo -Link: https://lore.kernel.org/r/20230226221004.138331-2-martin.blumenstingl@googlemail.com ---- - drivers/net/wireless/realtek/rtw88/mac.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - ---- a/drivers/net/wireless/realtek/rtw88/mac.c -+++ b/drivers/net/wireless/realtek/rtw88/mac.c -@@ -236,7 +236,7 @@ static int rtw_pwr_seq_parser(struct rtw - - ret = rtw_sub_pwr_seq_parser(rtwdev, intf_mask, cut_mask, cmd); - if (ret) -- return -EBUSY; -+ return ret; - - idx++; - } while (1); diff --git a/package/kernel/mac80211/patches/rtl/021-60-wifi-rtw88-mac-Return-the-original-error-from-rtw_ma.patch b/package/kernel/mac80211/patches/rtl/021-60-wifi-rtw88-mac-Return-the-original-error-from-rtw_ma.patch deleted file mode 100644 index c867fc4039..0000000000 --- a/package/kernel/mac80211/patches/rtl/021-60-wifi-rtw88-mac-Return-the-original-error-from-rtw_ma.patch +++ /dev/null @@ -1,41 +0,0 @@ -From 15c8e267dfa62f207ee1db666c822324e3362b84 Mon Sep 17 00:00:00 2001 -From: Martin Blumenstingl -Date: Sun, 26 Feb 2023 23:10:04 +0100 -Subject: [PATCH 60/85] wifi: rtw88: mac: Return the original error from - rtw_mac_power_switch() - -rtw_mac_power_switch() calls rtw_pwr_seq_parser() which can return --EINVAL, -EBUSY or 0. Propagate the original error code instead of -unconditionally returning -EINVAL in case of an error. - -Fixes: e3037485c68e ("rtw88: new Realtek 802.11ac driver") -Signed-off-by: Martin Blumenstingl -Reviewed-by: Ping-Ke Shih -Signed-off-by: Kalle Valo -Link: https://lore.kernel.org/r/20230226221004.138331-3-martin.blumenstingl@googlemail.com ---- - drivers/net/wireless/realtek/rtw88/mac.c | 6 ++++-- - 1 file changed, 4 insertions(+), 2 deletions(-) - ---- a/drivers/net/wireless/realtek/rtw88/mac.c -+++ b/drivers/net/wireless/realtek/rtw88/mac.c -@@ -250,6 +250,7 @@ static int rtw_mac_power_switch(struct r - const struct rtw_pwr_seq_cmd **pwr_seq; - u8 rpwm; - bool cur_pwr; -+ int ret; - - if (rtw_chip_wcpu_11ac(rtwdev)) { - rpwm = rtw_read8(rtwdev, rtwdev->hci.rpwm_addr); -@@ -273,8 +274,9 @@ static int rtw_mac_power_switch(struct r - return -EALREADY; - - pwr_seq = pwr_on ? chip->pwr_on_seq : chip->pwr_off_seq; -- if (rtw_pwr_seq_parser(rtwdev, pwr_seq)) -- return -EINVAL; -+ ret = rtw_pwr_seq_parser(rtwdev, pwr_seq); -+ if (ret) -+ return ret; - - if (pwr_on) - set_bit(RTW_FLAG_POWERON, rtwdev->flags); diff --git a/package/kernel/mac80211/patches/rtl/027-wifi-rtw88-main-Add-the-cpwm-rpwm-_addr-for-SDIO-bas.patch b/package/kernel/mac80211/patches/rtl/027-wifi-rtw88-main-Add-the-cpwm-rpwm-_addr-for-SDIO-bas.patch index 4f7fe2fa9d..3a8cad7bce 100644 --- a/package/kernel/mac80211/patches/rtl/027-wifi-rtw88-main-Add-the-cpwm-rpwm-_addr-for-SDIO-bas.patch +++ b/package/kernel/mac80211/patches/rtl/027-wifi-rtw88-main-Add-the-cpwm-rpwm-_addr-for-SDIO-bas.patch @@ -25,7 +25,7 @@ Link: https://lore.kernel.org/r/20230405200729.632435-5-martin.blumenstingl@goog bool rtw_disable_lps_deep_mode; EXPORT_SYMBOL(rtw_disable_lps_deep_mode); -@@ -1785,6 +1786,10 @@ static int rtw_chip_parameter_setup(stru +@@ -1800,6 +1801,10 @@ static int rtw_chip_parameter_setup(stru rtwdev->hci.rpwm_addr = 0x03d9; rtwdev->hci.cpwm_addr = 0x03da; break; diff --git a/package/kernel/mac80211/patches/rtl/028-wifi-rtw88-main-Reserve-8-bytes-of-extra-TX-headroom.patch b/package/kernel/mac80211/patches/rtl/028-wifi-rtw88-main-Reserve-8-bytes-of-extra-TX-headroom.patch index 9fb6dedea6..cdb1f53ea4 100644 --- a/package/kernel/mac80211/patches/rtl/028-wifi-rtw88-main-Reserve-8-bytes-of-extra-TX-headroom.patch +++ b/package/kernel/mac80211/patches/rtl/028-wifi-rtw88-main-Reserve-8-bytes-of-extra-TX-headroom.patch @@ -23,7 +23,7 @@ Link: https://lore.kernel.org/r/20230405200729.632435-6-martin.blumenstingl@goog --- a/drivers/net/wireless/realtek/rtw88/main.c +++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -2163,9 +2163,11 @@ int rtw_register_hw(struct rtw_dev *rtwd +@@ -2176,9 +2176,11 @@ int rtw_register_hw(struct rtw_dev *rtwd int max_tx_headroom = 0; int ret; diff --git a/package/kernel/mac80211/patches/rtl/032-wifi-rtw88-add-bitmap-for-dynamic-port-settings.patch b/package/kernel/mac80211/patches/rtl/032-wifi-rtw88-add-bitmap-for-dynamic-port-settings.patch index e84e977875..ea3afda58e 100644 --- a/package/kernel/mac80211/patches/rtl/032-wifi-rtw88-add-bitmap-for-dynamic-port-settings.patch +++ b/package/kernel/mac80211/patches/rtl/032-wifi-rtw88-add-bitmap-for-dynamic-port-settings.patch @@ -20,7 +20,7 @@ Link: https://lore.kernel.org/r/20230414121135.17828-2-pkshih@realtek.com --- a/drivers/net/wireless/realtek/rtw88/mac80211.c +++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -155,25 +155,30 @@ static int rtw_ops_add_interface(struct +@@ -146,25 +146,30 @@ static int rtw_ops_add_interface(struct struct rtw_vif *rtwvif = (struct rtw_vif *)vif->drv_priv; enum rtw_net_type net_type; u32 config = 0; @@ -54,7 +54,7 @@ Link: https://lore.kernel.org/r/20230414121135.17828-2-pkshih@realtek.com rtw_leave_lps_deep(rtwdev); switch (vif->type) { -@@ -195,6 +200,7 @@ static int rtw_ops_add_interface(struct +@@ -186,6 +191,7 @@ static int rtw_ops_add_interface(struct break; default: WARN_ON(1); @@ -62,9 +62,9 @@ Link: https://lore.kernel.org/r/20230414121135.17828-2-pkshih@realtek.com mutex_unlock(&rtwdev->mutex); return -EINVAL; } -@@ -236,6 +242,7 @@ static void rtw_ops_remove_interface(str - rtwvif->bcn_ctrl = 0; - config |= PORT_SET_BCN_CTRL; +@@ -425,6 +431,7 @@ static void rtw_ops_bss_info_changed(str + rtw_recalc_lps(rtwdev, NULL); + rtw_vif_port_config(rtwdev, rtwvif, config); + clear_bit(rtwvif->port, rtwdev->hw_port); @@ -72,7 +72,7 @@ Link: https://lore.kernel.org/r/20230414121135.17828-2-pkshih@realtek.com } --- a/drivers/net/wireless/realtek/rtw88/main.c +++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -610,6 +610,7 @@ free: +@@ -625,6 +625,7 @@ free: rcu_read_unlock(); rtw_iterate_stas_atomic(rtwdev, rtw_reset_sta_iter, rtwdev); rtw_iterate_vifs_atomic(rtwdev, rtw_reset_vif_iter, rtwdev); @@ -98,7 +98,7 @@ Link: https://lore.kernel.org/r/20230414121135.17828-2-pkshih@realtek.com enum rtw_wow_flags { RTW_WOW_FLAG_EN_MAGIC_PKT, RTW_WOW_FLAG_EN_REKEY_PKT, -@@ -2036,6 +2045,7 @@ struct rtw_dev { +@@ -2039,6 +2048,7 @@ struct rtw_dev { u8 sta_cnt; u32 rts_threshold; diff --git a/package/kernel/mac80211/patches/rtl/033-wifi-rtw88-add-port-switch-for-AP-mode.patch b/package/kernel/mac80211/patches/rtl/033-wifi-rtw88-add-port-switch-for-AP-mode.patch index 4467c77acb..9b59a1475d 100644 --- a/package/kernel/mac80211/patches/rtl/033-wifi-rtw88-add-port-switch-for-AP-mode.patch +++ b/package/kernel/mac80211/patches/rtl/033-wifi-rtw88-add-port-switch-for-AP-mode.patch @@ -20,17 +20,17 @@ Link: https://lore.kernel.org/r/20230414121135.17828-3-pkshih@realtek.com --- a/drivers/net/wireless/realtek/rtw88/mac80211.c +++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -212,6 +212,7 @@ static int rtw_ops_add_interface(struct +@@ -203,6 +203,7 @@ static int rtw_ops_add_interface(struct rtwvif->bcn_ctrl = bcn_ctrl; config |= PORT_SET_BCN_CTRL; rtw_vif_port_config(rtwdev, rtwvif, config); + rtw_core_port_switch(rtwdev, vif); + rtw_recalc_lps(rtwdev, vif); mutex_unlock(&rtwdev->mutex); - --- a/drivers/net/wireless/realtek/rtw88/main.c +++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -2251,6 +2251,85 @@ void rtw_unregister_hw(struct rtw_dev *r +@@ -2264,6 +2264,85 @@ void rtw_unregister_hw(struct rtw_dev *r } EXPORT_SYMBOL(rtw_unregister_hw); @@ -118,7 +118,7 @@ Link: https://lore.kernel.org/r/20230414121135.17828-3-pkshih@realtek.com MODULE_LICENSE("Dual BSD/GPL"); --- a/drivers/net/wireless/realtek/rtw88/main.h +++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -2198,4 +2198,5 @@ void rtw_set_txrx_1ss(struct rtw_dev *rt +@@ -2201,4 +2201,5 @@ void rtw_set_txrx_1ss(struct rtw_dev *rt void rtw_update_channel(struct rtw_dev *rtwdev, u8 center_channel, u8 primary_channel, enum rtw_supported_band band, enum rtw_bandwidth bandwidth); diff --git a/package/kernel/mac80211/patches/rtl/034-wifi-rtw88-8822c-extend-reserved-page-number.patch b/package/kernel/mac80211/patches/rtl/034-wifi-rtw88-8822c-extend-reserved-page-number.patch index cc4eef3184..1c919e1f49 100644 --- a/package/kernel/mac80211/patches/rtl/034-wifi-rtw88-8822c-extend-reserved-page-number.patch +++ b/package/kernel/mac80211/patches/rtl/034-wifi-rtw88-8822c-extend-reserved-page-number.patch @@ -34,7 +34,7 @@ Link: https://lore.kernel.org/r/20230414121135.17828-4-pkshih@realtek.com fifo->rsvd_pg_num = fifo->rsvd_drv_pg_num; --- a/drivers/net/wireless/realtek/rtw88/main.h +++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -1177,6 +1177,7 @@ struct rtw_chip_info { +@@ -1180,6 +1180,7 @@ struct rtw_chip_info { u32 txff_size; u32 rxff_size; u32 fw_rxff_size; diff --git a/package/kernel/mac80211/patches/rtl/035-wifi-rtw88-disallow-PS-during-AP-mode.patch b/package/kernel/mac80211/patches/rtl/035-wifi-rtw88-disallow-PS-during-AP-mode.patch index 060600f00a..2dbdea1538 100644 --- a/package/kernel/mac80211/patches/rtl/035-wifi-rtw88-disallow-PS-during-AP-mode.patch +++ b/package/kernel/mac80211/patches/rtl/035-wifi-rtw88-disallow-PS-during-AP-mode.patch @@ -17,7 +17,7 @@ Link: https://lore.kernel.org/r/20230414121135.17828-5-pkshih@realtek.com --- a/drivers/net/wireless/realtek/rtw88/mac80211.c +++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -449,12 +449,24 @@ static int rtw_ops_start_ap(struct ieee8 +@@ -445,12 +445,24 @@ static int rtw_ops_start_ap(struct ieee8 const struct rtw_chip_info *chip = rtwdev->chip; mutex_lock(&rtwdev->mutex); @@ -42,7 +42,7 @@ Link: https://lore.kernel.org/r/20230414121135.17828-5-pkshih@realtek.com static int rtw_ops_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, unsigned int link_id, u16 ac, -@@ -916,6 +928,7 @@ const struct ieee80211_ops rtw_ops = { +@@ -912,6 +924,7 @@ const struct ieee80211_ops rtw_ops = { .configure_filter = rtw_ops_configure_filter, .bss_info_changed = rtw_ops_bss_info_changed, .start_ap = rtw_ops_start_ap, @@ -63,7 +63,7 @@ Link: https://lore.kernel.org/r/20230414121135.17828-5-pkshih@realtek.com rtwdev->watch_dog_cnt++; --- a/drivers/net/wireless/realtek/rtw88/main.h +++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -2058,6 +2058,7 @@ struct rtw_dev { +@@ -2061,6 +2061,7 @@ struct rtw_dev { bool need_rfk; struct completion fw_scan_density; diff --git a/package/kernel/mac80211/patches/rtl/036-wifi-rtw88-refine-reserved-page-flow-for-AP-mode.patch b/package/kernel/mac80211/patches/rtl/036-wifi-rtw88-refine-reserved-page-flow-for-AP-mode.patch index 8820e3adfa..5f2b3f5c1b 100644 --- a/package/kernel/mac80211/patches/rtl/036-wifi-rtw88-refine-reserved-page-flow-for-AP-mode.patch +++ b/package/kernel/mac80211/patches/rtl/036-wifi-rtw88-refine-reserved-page-flow-for-AP-mode.patch @@ -40,7 +40,7 @@ Link: https://lore.kernel.org/r/20230414121300.17900-1-pkshih@realtek.com --- a/drivers/net/wireless/realtek/rtw88/mac80211.c +++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -417,6 +417,7 @@ static void rtw_ops_bss_info_changed(str +@@ -409,6 +409,7 @@ static void rtw_ops_bss_info_changed(str if (changed & BSS_CHANGED_BEACON) { rtw_set_dtim_period(rtwdev, conf->dtim_period); rtw_fw_download_rsvd_page(rtwdev); diff --git a/package/kernel/mac80211/patches/rtl/037-wifi-rtw88-prevent-scan-abort-with-other-VIFs.patch b/package/kernel/mac80211/patches/rtl/037-wifi-rtw88-prevent-scan-abort-with-other-VIFs.patch index 9263bde937..2b41ba76d5 100644 --- a/package/kernel/mac80211/patches/rtl/037-wifi-rtw88-prevent-scan-abort-with-other-VIFs.patch +++ b/package/kernel/mac80211/patches/rtl/037-wifi-rtw88-prevent-scan-abort-with-other-VIFs.patch @@ -43,7 +43,7 @@ Link: https://lore.kernel.org/r/20230414121312.17954-1-pkshih@realtek.com #endif --- a/drivers/net/wireless/realtek/rtw88/mac80211.c +++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -393,7 +393,8 @@ static void rtw_ops_bss_info_changed(str +@@ -385,7 +385,8 @@ static void rtw_ops_bss_info_changed(str * when disconnected by peer */ if (test_bit(RTW_FLAG_SCANNING, rtwdev->flags)) @@ -53,7 +53,7 @@ Link: https://lore.kernel.org/r/20230414121312.17954-1-pkshih@realtek.com } config |= PORT_SET_NET_TYPE; -@@ -870,7 +871,7 @@ static int rtw_ops_hw_scan(struct ieee80 +@@ -866,7 +867,7 @@ static int rtw_ops_hw_scan(struct ieee80 rtw_hw_scan_start(rtwdev, vif, req); ret = rtw_hw_scan_offload(rtwdev, vif, true); if (ret) { @@ -62,7 +62,7 @@ Link: https://lore.kernel.org/r/20230414121312.17954-1-pkshih@realtek.com rtw_err(rtwdev, "HW scan failed with status: %d\n", ret); } mutex_unlock(&rtwdev->mutex); -@@ -890,7 +891,7 @@ static void rtw_ops_cancel_hw_scan(struc +@@ -886,7 +887,7 @@ static void rtw_ops_cancel_hw_scan(struc return; mutex_lock(&rtwdev->mutex); diff --git a/package/kernel/mac80211/patches/rtl/038-wifi-rtw88-handle-station-mode-concurrent-scan-with-.patch b/package/kernel/mac80211/patches/rtl/038-wifi-rtw88-handle-station-mode-concurrent-scan-with-.patch index d0a1315e45..25d605fe68 100644 --- a/package/kernel/mac80211/patches/rtl/038-wifi-rtw88-handle-station-mode-concurrent-scan-with-.patch +++ b/package/kernel/mac80211/patches/rtl/038-wifi-rtw88-handle-station-mode-concurrent-scan-with-.patch @@ -62,7 +62,7 @@ Link: https://lore.kernel.org/r/20230414121323.18008-1-pkshih@realtek.com rtw_dbg(rtwdev, RTW_DBG_HW_SCAN, --- a/drivers/net/wireless/realtek/rtw88/mac80211.c +++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -404,7 +404,7 @@ static void rtw_ops_bss_info_changed(str +@@ -396,7 +396,7 @@ static void rtw_ops_bss_info_changed(str if (changed & BSS_CHANGED_BSSID) { ether_addr_copy(rtwvif->bssid, conf->bssid); config |= PORT_SET_BSSID; @@ -71,7 +71,7 @@ Link: https://lore.kernel.org/r/20230414121323.18008-1-pkshih@realtek.com rtw_clear_op_chan(rtwdev); else rtw_store_op_chan(rtwdev, true); -@@ -452,6 +452,7 @@ static int rtw_ops_start_ap(struct ieee8 +@@ -448,6 +448,7 @@ static int rtw_ops_start_ap(struct ieee8 mutex_lock(&rtwdev->mutex); rtwdev->ap_active = true; @@ -79,7 +79,7 @@ Link: https://lore.kernel.org/r/20230414121323.18008-1-pkshih@realtek.com chip->ops->phy_calibration(rtwdev); mutex_unlock(&rtwdev->mutex); -@@ -466,6 +467,8 @@ static void rtw_ops_stop_ap(struct ieee8 +@@ -462,6 +463,8 @@ static void rtw_ops_stop_ap(struct ieee8 mutex_lock(&rtwdev->mutex); rtwdev->ap_active = false; @@ -90,7 +90,7 @@ Link: https://lore.kernel.org/r/20230414121323.18008-1-pkshih@realtek.com --- a/drivers/net/wireless/realtek/rtw88/main.c +++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -830,6 +830,9 @@ void rtw_set_channel(struct rtw_dev *rtw +@@ -845,6 +845,9 @@ void rtw_set_channel(struct rtw_dev *rtw rtw_update_channel(rtwdev, center_chan, primary_chan, band, bandwidth); @@ -100,7 +100,7 @@ Link: https://lore.kernel.org/r/20230414121323.18008-1-pkshih@realtek.com chip->ops->set_channel(rtwdev, center_chan, bandwidth, hal->current_primary_channel_index); -@@ -2330,6 +2333,42 @@ void rtw_core_port_switch(struct rtw_dev +@@ -2343,6 +2346,42 @@ void rtw_core_port_switch(struct rtw_dev rtw_iterate_vifs(rtwdev, rtw_port_switch_iter, &iter_data); } @@ -145,7 +145,7 @@ Link: https://lore.kernel.org/r/20230414121323.18008-1-pkshih@realtek.com MODULE_LICENSE("Dual BSD/GPL"); --- a/drivers/net/wireless/realtek/rtw88/main.h +++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -2201,4 +2201,6 @@ void rtw_update_channel(struct rtw_dev * +@@ -2204,4 +2204,6 @@ void rtw_update_channel(struct rtw_dev * u8 primary_channel, enum rtw_supported_band band, enum rtw_bandwidth bandwidth); void rtw_core_port_switch(struct rtw_dev *rtwdev, struct ieee80211_vif *vif); diff --git a/package/kernel/mac80211/patches/rtl/039-wifi-rtw88-8822c-add-iface-combination.patch b/package/kernel/mac80211/patches/rtl/039-wifi-rtw88-8822c-add-iface-combination.patch index ddea655167..e409065ce8 100644 --- a/package/kernel/mac80211/patches/rtl/039-wifi-rtw88-8822c-add-iface-combination.patch +++ b/package/kernel/mac80211/patches/rtl/039-wifi-rtw88-8822c-add-iface-combination.patch @@ -44,7 +44,7 @@ Link: https://lore.kernel.org/r/20230414121331.18062-1-pkshih@realtek.com u16 rtw_desc_to_bitrate(u8 desc_rate) { struct ieee80211_rate rate; -@@ -2205,6 +2225,11 @@ int rtw_register_hw(struct rtw_dev *rtwd +@@ -2218,6 +2238,11 @@ int rtw_register_hw(struct rtw_dev *rtwd hw->wiphy->max_scan_ssids = RTW_SCAN_MAX_SSIDS; hw->wiphy->max_scan_ie_len = rtw_get_max_scan_ie_len(rtwdev); diff --git a/package/kernel/mac80211/patches/rtl/041-wifi-rtw88-rtw8821c-Fix-rfe_option-field-width.patch b/package/kernel/mac80211/patches/rtl/041-wifi-rtw88-rtw8821c-Fix-rfe_option-field-width.patch index c140b4b058..84696fbe63 100644 --- a/package/kernel/mac80211/patches/rtl/041-wifi-rtw88-rtw8821c-Fix-rfe_option-field-width.patch +++ b/package/kernel/mac80211/patches/rtl/041-wifi-rtw88-rtw8821c-Fix-rfe_option-field-width.patch @@ -39,15 +39,6 @@ Link: https://lore.kernel.org/r/20230417140358.2240429-3-s.hauer@pengutronix.de --- a/drivers/net/wireless/realtek/rtw88/rtw8821c.c +++ b/drivers/net/wireless/realtek/rtw88/rtw8821c.c -@@ -53,7 +53,7 @@ static int rtw8821c_read_efuse(struct rt - - map = (struct rtw8821c_efuse *)log_map; - -- efuse->rfe_option = map->rfe_option; -+ efuse->rfe_option = map->rfe_option & 0x1f; - efuse->rf_board_option = map->rf_board_option; - efuse->crystal_cap = map->xtal_k; - efuse->pa_type_2g = map->pa_type; @@ -1546,7 +1546,6 @@ static const struct rtw_rfe_def rtw8821c [2] = RTW_DEF_RFE_EXT(8821c, 0, 0, 2), [4] = RTW_DEF_RFE_EXT(8821c, 0, 0, 2), diff --git a/package/kernel/mac80211/patches/rtl/042-wifi-rtw88-set-pkg_type-correctly-for-specific-rtw88.patch b/package/kernel/mac80211/patches/rtl/042-wifi-rtw88-set-pkg_type-correctly-for-specific-rtw88.patch index e9954c515a..7caa3bd770 100644 --- a/package/kernel/mac80211/patches/rtl/042-wifi-rtw88-set-pkg_type-correctly-for-specific-rtw88.patch +++ b/package/kernel/mac80211/patches/rtl/042-wifi-rtw88-set-pkg_type-correctly-for-specific-rtw88.patch @@ -26,7 +26,7 @@ Link: https://lore.kernel.org/r/20230417140358.2240429-4-s.hauer@pengutronix.de --- a/drivers/net/wireless/realtek/rtw88/main.c +++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -2008,7 +2008,7 @@ static int rtw_chip_board_info_setup(str +@@ -2023,7 +2023,7 @@ static int rtw_chip_board_info_setup(str if (!rfe_def) return -ENODEV; @@ -34,10 +34,10 @@ Link: https://lore.kernel.org/r/20230417140358.2240429-4-s.hauer@pengutronix.de + rtw_phy_setup_phy_cond(rtwdev, hal->pkg_type); rtw_phy_init_tx_power(rtwdev); - if (rfe_def->agc_btg_tbl) + rtw_load_table(rtwdev, rfe_def->phy_pg_tbl); --- a/drivers/net/wireless/realtek/rtw88/main.h +++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -1900,6 +1900,7 @@ struct rtw_hal { +@@ -1903,6 +1903,7 @@ struct rtw_hal { u8 cut_version; u8 mp_chip; u8 oem_id; diff --git a/package/kernel/mac80211/patches/rtl/043-wifi-rtw88-call-rtw8821c_switch_rf_set-according-to-.patch b/package/kernel/mac80211/patches/rtl/043-wifi-rtw88-call-rtw8821c_switch_rf_set-according-to-.patch index da34691f35..8cfd69eeef 100644 --- a/package/kernel/mac80211/patches/rtl/043-wifi-rtw88-call-rtw8821c_switch_rf_set-according-to-.patch +++ b/package/kernel/mac80211/patches/rtl/043-wifi-rtw88-call-rtw8821c_switch_rf_set-according-to-.patch @@ -20,7 +20,7 @@ Link: https://lore.kernel.org/r/20230417140358.2240429-5-s.hauer@pengutronix.de --- a/drivers/net/wireless/realtek/rtw88/main.h +++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -1902,6 +1902,7 @@ struct rtw_hal { +@@ -1905,6 +1905,7 @@ struct rtw_hal { u8 oem_id; u8 pkg_type; struct rtw_phy_cond phy_cond; diff --git a/package/kernel/mac80211/patches/rtl/045-wifi-rtw88-Update-spelling-in-main.h.patch b/package/kernel/mac80211/patches/rtl/045-wifi-rtw88-Update-spelling-in-main.h.patch index 534ae86e06..09a50140c2 100644 --- a/package/kernel/mac80211/patches/rtl/045-wifi-rtw88-Update-spelling-in-main.h.patch +++ b/package/kernel/mac80211/patches/rtl/045-wifi-rtw88-Update-spelling-in-main.h.patch @@ -26,7 +26,7 @@ Link: https://lore.kernel.org/r/20230418-rtw88-starspell-v1-1-70e52a23979b@kerne #define RTW_MAX_CHANNEL_WIDTH RTW_CHANNEL_WIDTH_80 enum rtw_bandwidth { -@@ -1881,7 +1881,7 @@ enum rtw_sar_bands { +@@ -1884,7 +1884,7 @@ enum rtw_sar_bands { RTW_SAR_BAND_NR, }; @@ -35,7 +35,7 @@ Link: https://lore.kernel.org/r/20230418-rtw88-starspell-v1-1-70e52a23979b@kerne * which might not re-use same format with array common. */ union rtw_sar_cfg { -@@ -2032,7 +2032,7 @@ struct rtw_dev { +@@ -2035,7 +2035,7 @@ struct rtw_dev { struct rtw_tx_report tx_report; struct { diff --git a/package/kernel/mac80211/patches/rtl/048-wifi-rtw88-unlock-on-error-path-in-rtw_ops_add_inter.patch b/package/kernel/mac80211/patches/rtl/048-wifi-rtw88-unlock-on-error-path-in-rtw_ops_add_inter.patch index d067162caa..f1d8c46c79 100644 --- a/package/kernel/mac80211/patches/rtl/048-wifi-rtw88-unlock-on-error-path-in-rtw_ops_add_inter.patch +++ b/package/kernel/mac80211/patches/rtl/048-wifi-rtw88-unlock-on-error-path-in-rtw_ops_add_inter.patch @@ -17,7 +17,7 @@ Link: https://lore.kernel.org/r/ddd10a74-5982-4f65-8c59-c1cca558d239@kili.mounta --- a/drivers/net/wireless/realtek/rtw88/mac80211.c +++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -173,8 +173,10 @@ static int rtw_ops_add_interface(struct +@@ -164,8 +164,10 @@ static int rtw_ops_add_interface(struct mutex_lock(&rtwdev->mutex); port = find_first_zero_bit(rtwdev->hw_port, RTW_PORT_NUM); diff --git a/package/kernel/mac80211/patches/rtl/049-wifi-rtw88-use-work-to-update-rate-to-avoid-RCU-warn.patch b/package/kernel/mac80211/patches/rtl/049-wifi-rtw88-use-work-to-update-rate-to-avoid-RCU-warn.patch deleted file mode 100644 index e629593d17..0000000000 --- a/package/kernel/mac80211/patches/rtl/049-wifi-rtw88-use-work-to-update-rate-to-avoid-RCU-warn.patch +++ /dev/null @@ -1,132 +0,0 @@ -From bcafcb959a57a6890e900199690c5fc47da1a304 Mon Sep 17 00:00:00 2001 -From: Ping-Ke Shih -Date: Mon, 8 May 2023 16:54:29 +0800 -Subject: [PATCH 04/12] wifi: rtw88: use work to update rate to avoid RCU - warning - -The ieee80211_ops::sta_rc_update must be atomic, because -ieee80211_chan_bw_change() holds rcu_read lock while calling -drv_sta_rc_update(), so create a work to do original things. - - Voluntary context switch within RCU read-side critical section! - WARNING: CPU: 0 PID: 4621 at kernel/rcu/tree_plugin.h:318 - rcu_note_context_switch+0x571/0x5d0 - CPU: 0 PID: 4621 Comm: kworker/u16:2 Tainted: G W OE - Workqueue: phy3 ieee80211_chswitch_work [mac80211] - RIP: 0010:rcu_note_context_switch+0x571/0x5d0 - Call Trace: - - __schedule+0xb0/0x1460 - ? __mod_timer+0x116/0x360 - schedule+0x5a/0xc0 - schedule_timeout+0x87/0x150 - ? trace_raw_output_tick_stop+0x60/0x60 - wait_for_completion_timeout+0x7b/0x140 - usb_start_wait_urb+0x82/0x160 [usbcore - usb_control_msg+0xe3/0x140 [usbcore - rtw_usb_read+0x88/0xe0 [rtw_usb - rtw_usb_read8+0xf/0x10 [rtw_usb - rtw_fw_send_h2c_command+0xa0/0x170 [rtw_core - rtw_fw_send_ra_info+0xc9/0xf0 [rtw_core - drv_sta_rc_update+0x7c/0x160 [mac80211 - ieee80211_chan_bw_change+0xfb/0x110 [mac80211 - ieee80211_change_chanctx+0x38/0x130 [mac80211 - ieee80211_vif_use_reserved_switch+0x34e/0x900 [mac80211 - ieee80211_link_use_reserved_context+0x88/0xe0 [mac80211 - ieee80211_chswitch_work+0x95/0x170 [mac80211 - process_one_work+0x201/0x410 - worker_thread+0x4a/0x3b0 - ? process_one_work+0x410/0x410 - kthread+0xe1/0x110 - ? kthread_complete_and_exit+0x20/0x20 - ret_from_fork+0x1f/0x30 - - -Cc: stable@vger.kernel.org -Fixes: c1edc86472fc ("rtw88: add ieee80211:sta_rc_update ops") -Reported-by: Larry Finger -Link: https://lore.kernel.org/linux-wireless/f1e31e8e-f84e-3791-50fb-663a83c5c6e9@lwfinger.net/T/#t -Signed-off-by: Ping-Ke Shih -Tested-by: Larry Finger -Signed-off-by: Kalle Valo -Link: https://lore.kernel.org/r/20230508085429.46653-1-pkshih@realtek.com ---- - drivers/net/wireless/realtek/rtw88/mac80211.c | 2 +- - drivers/net/wireless/realtek/rtw88/main.c | 15 +++++++++++++++ - drivers/net/wireless/realtek/rtw88/main.h | 3 +++ - 3 files changed, 19 insertions(+), 1 deletion(-) - ---- a/drivers/net/wireless/realtek/rtw88/mac80211.c -+++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -920,7 +920,7 @@ static void rtw_ops_sta_rc_update(struct - struct rtw_sta_info *si = (struct rtw_sta_info *)sta->drv_priv; - - if (changed & IEEE80211_RC_BW_CHANGED) -- rtw_update_sta_info(rtwdev, si, true); -+ ieee80211_queue_work(rtwdev->hw, &si->rc_work); - } - - const struct ieee80211_ops rtw_ops = { ---- a/drivers/net/wireless/realtek/rtw88/main.c -+++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -319,6 +319,17 @@ static u8 rtw_acquire_macid(struct rtw_d - return mac_id; - } - -+static void rtw_sta_rc_work(struct work_struct *work) -+{ -+ struct rtw_sta_info *si = container_of(work, struct rtw_sta_info, -+ rc_work); -+ struct rtw_dev *rtwdev = si->rtwdev; -+ -+ mutex_lock(&rtwdev->mutex); -+ rtw_update_sta_info(rtwdev, si, true); -+ mutex_unlock(&rtwdev->mutex); -+} -+ - int rtw_sta_add(struct rtw_dev *rtwdev, struct ieee80211_sta *sta, - struct ieee80211_vif *vif) - { -@@ -329,12 +340,14 @@ int rtw_sta_add(struct rtw_dev *rtwdev, - if (si->mac_id >= RTW_MAX_MAC_ID_NUM) - return -ENOSPC; - -+ si->rtwdev = rtwdev; - si->sta = sta; - si->vif = vif; - si->init_ra_lv = 1; - ewma_rssi_init(&si->avg_rssi); - for (i = 0; i < ARRAY_SIZE(sta->txq); i++) - rtw_txq_init(rtwdev, sta->txq[i]); -+ INIT_WORK(&si->rc_work, rtw_sta_rc_work); - - rtw_update_sta_info(rtwdev, si, true); - rtw_fw_media_status_report(rtwdev, si->mac_id, true); -@@ -353,6 +366,8 @@ void rtw_sta_remove(struct rtw_dev *rtwd - struct rtw_sta_info *si = (struct rtw_sta_info *)sta->drv_priv; - int i; - -+ cancel_work_sync(&si->rc_work); -+ - rtw_release_macid(rtwdev, si->mac_id); - if (fw_exist) - rtw_fw_media_status_report(rtwdev, si->mac_id, false); ---- a/drivers/net/wireless/realtek/rtw88/main.h -+++ b/drivers/net/wireless/realtek/rtw88/main.h -@@ -743,6 +743,7 @@ struct rtw_txq { - DECLARE_EWMA(rssi, 10, 16); - - struct rtw_sta_info { -+ struct rtw_dev *rtwdev; - struct ieee80211_sta *sta; - struct ieee80211_vif *vif; - -@@ -767,6 +768,8 @@ struct rtw_sta_info { - - bool use_cfg_mask; - struct cfg80211_bitrate_mask *mask; -+ -+ struct work_struct rc_work; - }; - - enum rtw_bfee_role { diff --git a/package/kernel/mac80211/patches/rtl/056-wifi-rtw88-correct-PS-calculation-for-SUPPORTS_DYNAM.patch b/package/kernel/mac80211/patches/rtl/056-wifi-rtw88-correct-PS-calculation-for-SUPPORTS_DYNAM.patch deleted file mode 100644 index 5d15e8da86..0000000000 --- a/package/kernel/mac80211/patches/rtl/056-wifi-rtw88-correct-PS-calculation-for-SUPPORTS_DYNAM.patch +++ /dev/null @@ -1,145 +0,0 @@ -From 3918dd0177ee08970683a2c22a3388825d82fd79 Mon Sep 17 00:00:00 2001 -From: Ping-Ke Shih -Date: Sat, 27 May 2023 16:29:37 +0800 -Subject: [PATCH 11/12] wifi: rtw88: correct PS calculation for - SUPPORTS_DYNAMIC_PS - -This driver relies on IEEE80211_CONF_PS of hw->conf.flags to turn off PS or -turn on dynamic PS controlled by driver and firmware. Though this would be -incorrect, it did work before because the flag is always recalculated until -the commit 28977e790b5d ("wifi: mac80211: skip powersave recalc if driver SUPPORTS_DYNAMIC_PS") -is introduced by kernel 5.20 to skip to recalculate IEEE80211_CONF_PS -of hw->conf.flags if driver sets SUPPORTS_DYNAMIC_PS. - -Correct this by doing recalculation while BSS_CHANGED_PS is changed and -interface is added or removed. It is allowed to enter PS only if single -one station vif is working. Without this fix, driver doesn't enter PS -anymore that causes higher power consumption. - -Fixes: bcde60e599fb ("rtw88: remove misleading module parameter rtw_fw_support_lps") -Cc: stable@vger.kernel.org # 6.1+ -Signed-off-by: Ping-Ke Shih -Signed-off-by: Kalle Valo -Link: https://lore.kernel.org/r/20230527082939.11206-2-pkshih@realtek.com ---- - drivers/net/wireless/realtek/rtw88/mac80211.c | 14 +++--- - drivers/net/wireless/realtek/rtw88/main.c | 4 +- - drivers/net/wireless/realtek/rtw88/ps.c | 43 +++++++++++++++++++ - drivers/net/wireless/realtek/rtw88/ps.h | 2 + - 4 files changed, 52 insertions(+), 11 deletions(-) - ---- a/drivers/net/wireless/realtek/rtw88/mac80211.c -+++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -88,15 +88,6 @@ static int rtw_ops_config(struct ieee802 - } - } - -- if (changed & IEEE80211_CONF_CHANGE_PS) { -- if (hw->conf.flags & IEEE80211_CONF_PS) { -- rtwdev->ps_enabled = true; -- } else { -- rtwdev->ps_enabled = false; -- rtw_leave_lps(rtwdev); -- } -- } -- - if (changed & IEEE80211_CONF_CHANGE_CHANNEL) - rtw_set_channel(rtwdev); - -@@ -215,6 +206,7 @@ static int rtw_ops_add_interface(struct - config |= PORT_SET_BCN_CTRL; - rtw_vif_port_config(rtwdev, rtwvif, config); - rtw_core_port_switch(rtwdev, vif); -+ rtw_recalc_lps(rtwdev, vif); - - mutex_unlock(&rtwdev->mutex); - -@@ -246,6 +238,7 @@ static void rtw_ops_remove_interface(str - config |= PORT_SET_BCN_CTRL; - rtw_vif_port_config(rtwdev, rtwvif, config); - clear_bit(rtwvif->port, rtwdev->hw_port); -+ rtw_recalc_lps(rtwdev, NULL); - - mutex_unlock(&rtwdev->mutex); - } -@@ -440,6 +433,9 @@ static void rtw_ops_bss_info_changed(str - if (changed & BSS_CHANGED_ERP_SLOT) - rtw_conf_tx(rtwdev, rtwvif); - -+ if (changed & BSS_CHANGED_PS) -+ rtw_recalc_lps(rtwdev, NULL); -+ - rtw_vif_port_config(rtwdev, rtwvif, config); - - mutex_unlock(&rtwdev->mutex); ---- a/drivers/net/wireless/realtek/rtw88/main.c -+++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -271,8 +271,8 @@ static void rtw_watch_dog_work(struct wo - * more than two stations associated to the AP, then we can not enter - * lps, because fw does not handle the overlapped beacon interval - * -- * mac80211 should iterate vifs and determine if driver can enter -- * ps by passing IEEE80211_CONF_PS to us, all we need to do is to -+ * rtw_recalc_lps() iterate vifs and determine if driver can enter -+ * ps by vif->type and vif->cfg.ps, all we need to do here is to - * get that vif and check if device is having traffic more than the - * threshold. - */ ---- a/drivers/net/wireless/realtek/rtw88/ps.c -+++ b/drivers/net/wireless/realtek/rtw88/ps.c -@@ -299,3 +299,46 @@ void rtw_leave_lps_deep(struct rtw_dev * - - __rtw_leave_lps_deep(rtwdev); - } -+ -+struct rtw_vif_recalc_lps_iter_data { -+ struct rtw_dev *rtwdev; -+ struct ieee80211_vif *found_vif; -+ int count; -+}; -+ -+static void __rtw_vif_recalc_lps(struct rtw_vif_recalc_lps_iter_data *data, -+ struct ieee80211_vif *vif) -+{ -+ if (data->count < 0) -+ return; -+ -+ if (vif->type != NL80211_IFTYPE_STATION) { -+ data->count = -1; -+ return; -+ } -+ -+ data->count++; -+ data->found_vif = vif; -+} -+ -+static void rtw_vif_recalc_lps_iter(void *data, u8 *mac, -+ struct ieee80211_vif *vif) -+{ -+ __rtw_vif_recalc_lps(data, vif); -+} -+ -+void rtw_recalc_lps(struct rtw_dev *rtwdev, struct ieee80211_vif *new_vif) -+{ -+ struct rtw_vif_recalc_lps_iter_data data = { .rtwdev = rtwdev }; -+ -+ if (new_vif) -+ __rtw_vif_recalc_lps(&data, new_vif); -+ rtw_iterate_vifs(rtwdev, rtw_vif_recalc_lps_iter, &data); -+ -+ if (data.count == 1 && data.found_vif->cfg.ps) { -+ rtwdev->ps_enabled = true; -+ } else { -+ rtwdev->ps_enabled = false; -+ rtw_leave_lps(rtwdev); -+ } -+} ---- a/drivers/net/wireless/realtek/rtw88/ps.h -+++ b/drivers/net/wireless/realtek/rtw88/ps.h -@@ -23,4 +23,6 @@ void rtw_enter_lps(struct rtw_dev *rtwde - void rtw_leave_lps(struct rtw_dev *rtwdev); - void rtw_leave_lps_deep(struct rtw_dev *rtwdev); - enum rtw_lps_deep_mode rtw_get_lps_deep_mode(struct rtw_dev *rtwdev); -+void rtw_recalc_lps(struct rtw_dev *rtwdev, struct ieee80211_vif *new_vif); -+ - #endif diff --git a/package/kernel/mac80211/patches/rtl/063-wifi-rtw88-Stop-high-queue-during-scan.patch b/package/kernel/mac80211/patches/rtl/063-wifi-rtw88-Stop-high-queue-during-scan.patch index 68c28a72ae..19cfbe2fc1 100644 --- a/package/kernel/mac80211/patches/rtl/063-wifi-rtw88-Stop-high-queue-during-scan.patch +++ b/package/kernel/mac80211/patches/rtl/063-wifi-rtw88-Stop-high-queue-during-scan.patch @@ -18,7 +18,7 @@ Link: https://lore.kernel.org/r/20230616125540.36877-5-pkshih@realtek.com --- a/drivers/net/wireless/realtek/rtw88/main.c +++ b/drivers/net/wireless/realtek/rtw88/main.c -@@ -2403,10 +2403,13 @@ void rtw_core_enable_beacon(struct rtw_d +@@ -2401,10 +2401,13 @@ void rtw_core_enable_beacon(struct rtw_d if (!rtwdev->ap_active) return; diff --git a/package/kernel/mac80211/patches/rtl/065-wifi-rtw88-fix-not-entering-PS-mode-after-AP-stops.patch b/package/kernel/mac80211/patches/rtl/065-wifi-rtw88-fix-not-entering-PS-mode-after-AP-stops.patch index 0508a19c42..03f791529b 100644 --- a/package/kernel/mac80211/patches/rtl/065-wifi-rtw88-fix-not-entering-PS-mode-after-AP-stops.patch +++ b/package/kernel/mac80211/patches/rtl/065-wifi-rtw88-fix-not-entering-PS-mode-after-AP-stops.patch @@ -82,7 +82,7 @@ Link: https://lore.kernel.org/r/20230616125540.36877-7-pkshih@realtek.com void rtw_fw_inform_rfk_status(struct rtw_dev *rtwdev, bool start); --- a/drivers/net/wireless/realtek/rtw88/mac80211.c +++ b/drivers/net/wireless/realtek/rtw88/mac80211.c -@@ -382,6 +382,7 @@ static void rtw_ops_bss_info_changed(str +@@ -381,6 +381,7 @@ static void rtw_ops_bss_info_changed(str rtw_fw_download_rsvd_page(rtwdev); rtw_send_rsvd_page_h2c(rtwdev); @@ -108,7 +108,7 @@ Link: https://lore.kernel.org/r/20230616125540.36877-7-pkshih@realtek.com si->rtwdev = rtwdev; si->sta = sta; si->vif = vif; -@@ -2340,6 +2343,9 @@ static void rtw_port_switch_iter(void *d +@@ -2338,6 +2341,9 @@ static void rtw_port_switch_iter(void *d rtw_dbg(rtwdev, RTW_DBG_STATE, "AP port switch from %d -> %d\n", rtwvif_ap->port, rtwvif_target->port); @@ -118,7 +118,7 @@ Link: https://lore.kernel.org/r/20230616125540.36877-7-pkshih@realtek.com reg1 = &rtwvif_ap->conf->net_type; reg2 = &rtwvif_target->conf->net_type; rtw_swap_reg_mask(rtwdev, reg1, reg2); -@@ -2358,6 +2364,8 @@ static void rtw_port_switch_iter(void *d +@@ -2356,6 +2362,8 @@ static void rtw_port_switch_iter(void *d swap(rtwvif_target->port, rtwvif_ap->port); swap(rtwvif_target->conf, rtwvif_ap->conf); diff --git a/package/kernel/mac80211/patches/subsys/600-mac80211-allow-vht-on-2g.patch b/package/kernel/mac80211/patches/subsys/600-mac80211-allow-vht-on-2g.patch index 5d8742ba95..13c37ba35f 100644 --- a/package/kernel/mac80211/patches/subsys/600-mac80211-allow-vht-on-2g.patch +++ b/package/kernel/mac80211/patches/subsys/600-mac80211-allow-vht-on-2g.patch @@ -1,6 +1,6 @@ --- a/net/mac80211/vht.c +++ b/net/mac80211/vht.c -@@ -135,7 +135,8 @@ ieee80211_vht_cap_ie_to_sta_vht_cap(stru +@@ -137,7 +137,8 @@ ieee80211_vht_cap_ie_to_sta_vht_cap(stru have_80mhz = false; for (i = 0; i < sband->n_channels; i++) { if (sband->channels[i].flags & (IEEE80211_CHAN_DISABLED | @@ -24,7 +24,7 @@ have_80mhz = true; --- a/net/mac80211/mlme.c +++ b/net/mac80211/mlme.c -@@ -4744,7 +4744,8 @@ static int ieee80211_prep_channel(struct +@@ -4849,7 +4849,8 @@ static int ieee80211_prep_channel(struct have_80mhz = false; for (i = 0; i < sband->n_channels; i++) { if (sband->channels[i].flags & (IEEE80211_CHAN_DISABLED |