2022-05-02 08:06:44

by Ping-Ke Shih

[permalink] [raw]
Subject: [PATCH v2 00/16] rtw89: 8852c: add RFK and then enable 8852ce in Makefile and Kconfig

After this patchset, basic functions are ready, so we can enable 8852ce.
It can play as STA, AP and monitor modes. The BT coexistence and power save
are still cooking, but these don't affect the performance of Wi-Fi only.

Patches 1-9 are related to RF calibration (RFK). These RFK can be called
once interface is going up, or when we are going to connect to AP in
certain channel, or band is changed. The general steps of calibration are
to backup registers (optional) and set a set of registers before doing
calibration according to channels or something else, and then trigger the
calibration and poll if calibration is complete. Then, check the result
is positive or not to decide to adjust parameters and re-trigger again.
If the result is okay, set registers accordingly, and restore registers
we backup before (optional).

Patches 10-11 are to add necessary chip_ops and chip_info.

Patch 12 is to fine tune polling interval to enter/leave low power mode.
Since 8852ce will do this more frequently, polling interval become more
important.

Patch 13-14 are to correct registers settings found when we develop 8852ce.

Patch 15 is to fix compiler warnings reported by clang.

Final patch is to add 8852ce to Makefile and Kconfig, so user can use it
with firmware version 0.27.20.0 that I will send out after this patchset.

v2: add patch 15 to fix clang warning

Ping-Ke Shih (16):
rtw89: 8852c: rfk: add RFK tables
rtw89: 8852c: rfk: add DACK
rtw89: 8852c: rfk: add LCK
rtw89: 8852c: rfk: add TSSI
rtw89: 8852c: rfk: add RCK
rtw89: 8852c: rfk: add RX DCK
rtw89: 8852c: rfk: add IQK
rtw89: 8852c: rfk: add DPK
rtw89: 8852c: rfk: get calibrated channels to notify firmware
rtw89: 8852c: add chip_ops::bb_ctrl_btc_preagc
rtw89: 8852c: add basic and remaining chip_info
rtw89: ps: fine tune polling interval while changing low power mode
rtw89: correct AID settings of beamformee
rtw89: 8852c: correct register definitions used by 8852c
rtw89: 8852c: fix warning of FIELD_PREP() mask type
rtw89: 8852c: add 8852ce to Makefile and Kconfig

drivers/net/wireless/realtek/rtw89/Kconfig | 18 +-
drivers/net/wireless/realtek/rtw89/Makefile | 9 +
drivers/net/wireless/realtek/rtw89/core.h | 19 +-
drivers/net/wireless/realtek/rtw89/mac.c | 7 +-
drivers/net/wireless/realtek/rtw89/reg.h | 219 +-
.../net/wireless/realtek/rtw89/rtw8852a_rfk.c | 8 +-
drivers/net/wireless/realtek/rtw89/rtw8852c.c | 193 +-
.../net/wireless/realtek/rtw89/rtw8852c_rfk.c | 3812 +++++++++++++++++
.../net/wireless/realtek/rtw89/rtw8852c_rfk.h | 14 +
.../realtek/rtw89/rtw8852c_rfk_table.c | 781 ++++
.../realtek/rtw89/rtw8852c_rfk_table.h | 67 +
11 files changed, 5112 insertions(+), 35 deletions(-)
create mode 100644 drivers/net/wireless/realtek/rtw89/rtw8852c_rfk_table.c
create mode 100644 drivers/net/wireless/realtek/rtw89/rtw8852c_rfk_table.h

--
2.25.1


2022-05-03 01:02:58

by Ping-Ke Shih

[permalink] [raw]
Subject: [PATCH v2 16/16] rtw89: 8852c: add 8852ce to Makefile and Kconfig

This initial vesion is usable now. It can support STA, AP and monitor
modes, so we can add 8852ce to Kconfig and Makefile.

We are still working on some features, such as deep power save, and BT
coexistence. But, this version still can have a good WiFi-only performance
already, and will continue to fine tune power consumption.

Signed-off-by: Ping-Ke Shih <[email protected]>
---
drivers/net/wireless/realtek/rtw89/Kconfig | 18 ++++++++++++++++--
drivers/net/wireless/realtek/rtw89/Makefile | 9 +++++++++
2 files changed, 25 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/realtek/rtw89/Kconfig b/drivers/net/wireless/realtek/rtw89/Kconfig
index dd02b6a6790e3..93e09400aac49 100644
--- a/drivers/net/wireless/realtek/rtw89/Kconfig
+++ b/drivers/net/wireless/realtek/rtw89/Kconfig
@@ -19,8 +19,11 @@ config RTW89_PCI
config RTW89_8852A
tristate

+config RTW89_8852C
+ tristate
+
config RTW89_8852AE
- tristate "Realtek 8852AE PCI wireless network adapter"
+ tristate "Realtek 8852AE PCI wireless network (Wi-Fi 6) adapter"
depends on PCI
select RTW89_CORE
select RTW89_PCI
@@ -28,7 +31,18 @@ config RTW89_8852AE
help
Select this option will enable support for 8852AE chipset

- 802.11ax PCIe wireless network adapter
+ 802.11ax PCIe wireless network (Wi-Fi 6) adapter
+
+config RTW89_8852CE
+ tristate "Realtek 8852CE PCI wireless network (Wi-Fi 6E) adapter"
+ depends on PCI
+ select RTW89_CORE
+ select RTW89_PCI
+ select RTW89_8852C
+ help
+ Select this option will enable support for 8852CE chipset
+
+ 802.11ax PCIe wireless network (Wi-Fi 6E) adapter

config RTW89_DEBUG
bool
diff --git a/drivers/net/wireless/realtek/rtw89/Makefile b/drivers/net/wireless/realtek/rtw89/Makefile
index 012ae60c0b811..3006482d25c77 100644
--- a/drivers/net/wireless/realtek/rtw89/Makefile
+++ b/drivers/net/wireless/realtek/rtw89/Makefile
@@ -23,6 +23,15 @@ rtw89_8852a-objs := rtw8852a.o \
obj-$(CONFIG_RTW89_8852AE) += rtw89_8852ae.o
rtw89_8852ae-objs := rtw8852ae.o

+obj-$(CONFIG_RTW89_8852C) += rtw89_8852c.o
+rtw89_8852c-objs := rtw8852c.o \
+ rtw8852c_table.o \
+ rtw8852c_rfk.o \
+ rtw8852c_rfk_table.o
+
+obj-$(CONFIG_RTW89_8852CE) += rtw89_8852ce.o
+rtw89_8852ce-objs := rtw8852ce.o
+
rtw89_core-$(CONFIG_RTW89_DEBUG) += debug.o

obj-$(CONFIG_RTW89_PCI) += rtw89_pci.o
--
2.25.1