mirror of
https://github.com/FUjr/gl-infra-builder.git
synced 2025-12-16 09:10:02 +00:00
55 lines
1.9 KiB
Diff
55 lines
1.9 KiB
Diff
From a5c1827c83ba3c4e11e32d3a0c5e5fbdae9c475e Mon Sep 17 00:00:00 2001
|
|
From: Jianhui Zhao <jianhui.zhao@gl-inet.com>
|
|
Date: Mon, 26 Apr 2021 15:55:33 +0800
|
|
Subject: [PATCH 15/26] package/mac80211: support tuningcaps for QCA9531
|
|
|
|
Signed-off-by: Jianhui Zhao <jianhui.zhao@gl-inet.com>
|
|
---
|
|
.../patches/ath/984-fix-9531-tuningcaps.patch | 34 +++++++++++++++++++
|
|
1 file changed, 34 insertions(+)
|
|
create mode 100644 package/kernel/mac80211/patches/ath/984-fix-9531-tuningcaps.patch
|
|
|
|
diff --git a/package/kernel/mac80211/patches/ath/984-fix-9531-tuningcaps.patch b/package/kernel/mac80211/patches/ath/984-fix-9531-tuningcaps.patch
|
|
new file mode 100644
|
|
index 0000000000..7bda37bd45
|
|
--- /dev/null
|
|
+++ b/package/kernel/mac80211/patches/ath/984-fix-9531-tuningcaps.patch
|
|
@@ -0,0 +1,34 @@
|
|
+--- a/drivers/net/wireless/ath/ath9k/ar9003_eeprom.c
|
|
++++ b/drivers/net/wireless/ath/ath9k/ar9003_eeprom.c
|
|
+@@ -4049,16 +4049,25 @@ static void ar9003_hw_apply_tuning_caps(
|
|
+ struct ar9300_eeprom *eep = &ah->eeprom.ar9300_eep;
|
|
+ u8 tuning_caps_param = eep->baseEepHeader.params_for_tuning_caps[0];
|
|
+
|
|
+- if (AR_SREV_9340(ah) || AR_SREV_9531(ah))
|
|
++ if (AR_SREV_9340(ah))
|
|
+ return;
|
|
+
|
|
+- if (eep->baseEepHeader.featureEnable & 0x40) {
|
|
+- tuning_caps_param &= 0x7f;
|
|
+- REG_RMW_FIELD(ah, AR_CH0_XTAL, AR_CH0_XTAL_CAPINDAC,
|
|
++ if (eep->baseEepHeader.featureEnable & 0x40) {
|
|
++ tuning_caps_param &= 0x7f;
|
|
++ if(AR_SREV_9531(ah))
|
|
++ {
|
|
++ REG_RMW_FIELD(ah, 0x162c0, AR_CH0_XTAL_CAPINDAC,
|
|
++ tuning_caps_param);
|
|
++ REG_RMW_FIELD(ah, 0x162c0, AR_CH0_XTAL_CAPOUTDAC,
|
|
++ tuning_caps_param);
|
|
++ }
|
|
++ else{
|
|
++ REG_RMW_FIELD(ah, AR_CH0_XTAL, AR_CH0_XTAL_CAPINDAC,
|
|
+ tuning_caps_param);
|
|
+- REG_RMW_FIELD(ah, AR_CH0_XTAL, AR_CH0_XTAL_CAPOUTDAC,
|
|
++ REG_RMW_FIELD(ah, AR_CH0_XTAL, AR_CH0_XTAL_CAPOUTDAC,
|
|
+ tuning_caps_param);
|
|
+- }
|
|
++ }
|
|
++ }
|
|
+ }
|
|
+
|
|
+ static void ar9003_hw_quick_drop_apply(struct ath_hw *ah, u16 freq)
|
|
--
|
|
2.17.1
|
|
|