summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/realtek/rtw89/phy_be.c
diff options
context:
space:
mode:
authorPing-Ke Shih <pkshih@realtek.com>2023-08-22 15:58:21 +0300
committerKalle Valo <kvalo@kernel.org>2023-08-25 12:59:54 +0300
commit1165f5719229882442e67ad845a07491b0795ded (patch)
tree2a714596841a78f2341248731169c47c1707ba68 /drivers/net/wireless/realtek/rtw89/phy_be.c
parent9d87e7dc930e149def617c152f03ed97e3d7d899 (diff)
downloadlinux-1165f5719229882442e67ad845a07491b0795ded.tar.xz
wifi: rtw89: phy: add phy_gen_def::cr_base to support WiFi 7 chips
cr_base is base address of PHY control register. The base of WiFi 6 and 7 chips are 0x1_0000 and 0x2_0000 respectively, so define them accordingly. For example, if PHY address is 0x1330, absolute address is 0x1_1330 for WiFi 6 chips, and 0x2_1330 for WiFi 7 chips. Meanwhile, there are two copies of PHY hardware named PHY0 and PHY1. The offset between them is 0x2_0000, so the base address of PHY0 and PHY1 are 0x2_0000 and 0x4_0000 respectively. Signed-off-by: Ping-Ke Shih <pkshih@realtek.com> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://lore.kernel.org/r/20230822125822.23817-6-pkshih@realtek.com
Diffstat (limited to 'drivers/net/wireless/realtek/rtw89/phy_be.c')
-rw-r--r--drivers/net/wireless/realtek/rtw89/phy_be.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/net/wireless/realtek/rtw89/phy_be.c b/drivers/net/wireless/realtek/rtw89/phy_be.c
new file mode 100644
index 000000000000..143f900d29a6
--- /dev/null
+++ b/drivers/net/wireless/realtek/rtw89/phy_be.c
@@ -0,0 +1,10 @@
+// SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause
+/* Copyright(c) 2023 Realtek Corporation
+ */
+
+#include "phy.h"
+
+const struct rtw89_phy_gen_def rtw89_phy_gen_be = {
+ .cr_base = 0x20000,
+};
+EXPORT_SYMBOL(rtw89_phy_gen_be);