Commit graph

22 commits

Author SHA1 Message Date
Zong-Zhe Yang
969efe4ef8 wifi: rtw89: 8852c: update TX power tables to R69.1 (2 of 2)
Deconfigure fields for 6GHz SP. Don't use these set of values until
getting certification of 6GHz SP regulation. Without configuring
these fields, driver takes world-wide values when 6GHz SP cases.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Link: https://msgid.link/20240412115729.8316-5-pkshih@realtek.com
2024-04-18 09:09:43 +08:00
Zong-Zhe Yang
a08f9f2166 wifi: rtw89: 8852c: update TX power tables to R69.1 (1 of 2)
Deconfigure fields for 6GHz SP. Don't use these set of values until
getting certification of 6GHz SP regulation. Without configuring
these fields, driver takes world-wide values when 6GHz SP cases.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Link: https://msgid.link/20240412115729.8316-4-pkshih@realtek.com
2024-04-18 09:09:29 +08:00
Zong-Zhe Yang
973719185a wifi: rtw89: 8852c: update TX power tables to R69
Configure applicable values for IC (Industry Canada) on 5.9GHz.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Link: https://msgid.link/20240329015251.22762-3-pkshih@realtek.com
2024-04-03 10:41:43 +08:00
Zong-Zhe Yang
ae22f2b9f5 wifi: rtw89: 8852c: update TX power tables to R67
Update TX power tables to RF version R67.
* tweak values of CN for its new regulation
* configure values of Thailand for its regulation
* add TX shape table for RU limit

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
2023-10-03 14:32:19 +03:00
Zong-Zhe Yang
f6d601c759 wifi: rtw89: phy: extend TX power common stuffs for Wi-Fi 7 chips
The following are introduced for Wi-Fi 7 chips.
1. take BW/OFDMA into account on TX power by rate
2. increase TX power offset types up to EHT
3. split TX shape into tx_shape_lmt and tx_shape_lmt_ru

If functions which are only for AX, they always access TX power by rate
with BW/OFDMA = 0/0, and they don't access tx_shape's lmt_ru section.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230920074322.42898-7-pkshih@realtek.com
2023-09-22 10:43:59 +03:00
Zong-Zhe Yang
4cc05e3156 wifi: rtw89: indicate TX power by rate table inside RFE parameter
For next-generation chips, TX power by rate table comes from RFE (RF
front end) parameter. It can be different according to RFE type. So,
we indicate TX power by rate table inside RFE parameter ahead. For
current chips, even with different RFE types, a chip is configured
with a single TX power by rate table. So, this commit doesn't really
affect these currently supported chips.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230920074322.42898-4-pkshih@realtek.com
2023-09-22 10:43:58 +03:00
Zong-Zhe Yang
1bf24172cc wifi: rtw89: indicate TX shape table inside RFE parameter
For next-generation chips, TX shape table comes from RFE (RF front end)
parameter. It can be different according to RFE type. So, we indicate
TX shape table inside RFE parameter ahead. For current chips, even with
different RFE types, a chip is configured with a single TX shape table.
So, this commit doesn't really affect these currently supported chips.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230920074322.42898-3-pkshih@realtek.com
2023-09-22 10:43:57 +03:00
Kuan-Chung Chen
8f969ba1de wifi: rtw89: 8852c: Update bandedge parameters for better performance
TSSI configures bandedge to TX proper waveform, these new bandedge
parameters improve the accuracy of transmit power compensation.
This helps to avoid throughput degradation.

Signed-off-by: Kuan-Chung Chen <damon.chen@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230830092849.153251-2-pkshih@realtek.com
2023-09-04 20:34:00 +03:00
Zong-Zhe Yang
b4a283fb62 wifi: rtw89: TX power stuffs replace confusing naming of _max with _num
Some old declarations about TX power stuffs were named with confusing
`_max`. But, they mean "the number of". So we change them to be named
with `_num`.

(No logic is changed.)

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230616060523.28396-1-pkshih@realtek.com
2023-06-21 12:48:10 +03:00
Ping-Ke Shih
5883fc2ef8 wifi: rtw89: 8852c: update RF radio A/B parameters to R63
Update 8852c radio A/B parameters from internal HALRF_029_00_102 R63.

Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230602150556.36777-9-pkshih@realtek.com
2023-06-08 18:58:53 +03:00
Zong-Zhe Yang
dad142c3f5 wifi: rtw89: 8852c: update TX power tables to R63 with 6 GHz power type (3 of 3)
Update TX power tables to RF version R63.

TX power tables' changes:
* TX power byrate:
	tweak a bit
* TX power limit, TX power limit RU, TX power shape:
	configure values for MEXICO, UKRAINE, CHILE, QATAR
	tweak a bit on other configured values
* 6 GHz TX power limit, 6 GHz TX power limit RU:
	add an extra dimension for 6 GHz regulatory power type, i.e.
	STD (standard power), LPI (low power indoor), VLP (very low power)

Besides, we adjust TX power handling at 6 GHz in phy to consider 6 GHz
regulatory power type.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230602150556.36777-8-pkshih@realtek.com
2023-06-08 18:58:53 +03:00
Zong-Zhe Yang
2a8ec45f4d wifi: rtw89: 8852c: update TX power tables to R63 with 6 GHz power type (2 of 3)
Update TX power tables to RF version R63.

TX power tables' changes:
* TX power byrate:
	tweak a bit
* TX power limit, TX power limit RU, TX power shape:
	configure values for MEXICO, UKRAINE, CHILE, QATAR
	tweak a bit on other configured values
* 6 GHz TX power limit, 6 GHz TX power limit RU:
	add an extra dimension for 6 GHz regulatory power type, i.e.
	STD (standard power), LPI (low power indoor), VLP (very low power)

Besides, we adjust TX power handling at 6 GHz in phy to consider 6 GHz
regulatory power type.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230602150556.36777-7-pkshih@realtek.com
2023-06-08 18:58:52 +03:00
Zong-Zhe Yang
b742394cfe wifi: rtw89: 8852c: update TX power tables to R63 with 6 GHz power type (1 of 3)
Update TX power tables to RF version R63.

TX power tables' changes:
* TX power byrate:
	tweak a bit
* TX power limit, TX power limit RU, TX power shape:
	configure values for MEXICO, UKRAINE, CHILE, QATAR
	tweak a bit on other configured values
* 6 GHz TX power limit, 6 GHz TX power limit RU:
	add an extra dimension for 6 GHz regulatory power type, i.e.
	STD (standard power), LPI (low power indoor), VLP (very low power)

Besides, we adjust TX power handling at 6 GHz in phy to consider 6 GHz
regulatory power type.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230602150556.36777-6-pkshih@realtek.com
2023-06-08 18:58:52 +03:00
Zong-Zhe Yang
5395482afa wifi: rtw89: support parameter tables by RFE type
One chip can have different RFE (RF front end) types which we will judge
at runtime. And, different RFE types may use different RF parameter tables.
Though we didn't really meet this case previously, we are going to meet it
on upcoming chip RTL8851B. So, this commit handles parameter tables for
runtime RFE type.

We now encapsulate rtw89_txpwr_rule_<2/5/6>ghz tables into rtw89_rfe_parms.
Then, each chip defines its default parameter tables, and if needed, it can
configure extra parameter tables by RFE type. Finally we determine runtime
parameter tables by RFE type if one is configured. Otherwise, we use the
default parameter tables.

For now, we just move all settings under default parameter tables. We will
configure parameter tables by RFE types in separate commits afterwards.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230330080331.37155-1-pkshih@realtek.com
2023-04-14 15:22:24 +03:00
Ping-Ke Shih
a9ee25c32f wifi: rtw89: 8852c: update BB parameters to v28
Update BB parameters along with internal tag HALBB_027_067_07.

Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220930133659.7789-1-pkshih@realtek.com
2022-10-05 10:42:48 +03:00
Zong-Zhe Yang
07732caa51 wifi: rtw89: 8852c: update TX power tables to R49
TX power byrate:
	doesn't change

TX power limit:
	configure values for KCC and UK
	refine a bit configuration vales

TX power limit_ru:
	configure values for KCC and UK
	refine a bit configuration values
	change 6GHz to follow indoor setting
	configure 6GHz values for ETSI

TX power shape:
	change with TX power limit/limit_ru

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220812093116.56791-4-pkshih@realtek.com
2022-09-02 11:34:23 +03:00
Ping-Ke Shih
39ac0c27d0 wifi: rtw89: 8852c: update RF radio A/B parameters to R49
Update 8852c radio A/B parameters from internal HALRF_027_00_071 R49.

Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220812093116.56791-3-pkshih@realtek.com
2022-09-02 11:34:22 +03:00
Zong-Zhe Yang
aebc048d10 rtw89: 8852c: update txpwr tables to HALRF_027_00_052
Update notes:
	update the following to HALRF_027_00_052
		TX power by rate table
		TX power limit table
		TX power limit RU table
	TX shape table doesn't seem to be changed on HALRF_027_00_052

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220516005215.5878-5-pkshih@realtek.com
2022-05-17 18:31:59 +03:00
Ping-Ke Shih
c7845551bf rtw89: 8852c: phy: configure TSSI bandedge
TSSI is used to manage TX power with thermal value as a factor. This patch
is to configure bandedge to TX proper waveform.

Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220414062027.62638-5-pkshih@realtek.com
2022-04-23 15:44:49 +03:00
Zong-Zhe Yang
c6badab206 rtw89: 8852c: add TX power track tables
TX power track tables are used to do TX power compensation according to
thermal value. In order to work in existing and new chip, add new 6G
entries, and change type from u8 to s8.

Internal version table is HALRF_027_00_031.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220414062027.62638-4-pkshih@realtek.com
2022-04-23 15:44:49 +03:00
Ping-Ke Shih
342475ac51 rtw89: 8852c: add TX power by rate and limit tables
TX power depends on rate, but must follow regulation for specific country.
Once asked to set channel, we configure registers according to these TX
power tables.

Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220414062027.62638-3-pkshih@realtek.com
2022-04-23 15:44:49 +03:00
Ping-Ke Shih
eefad995c2 rtw89: 8852c: add BB and RF parameters tables
These parameters are used to initialize BB and RF hardware when we are
going to bring up interface and start to transmit and receive.

Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220414062027.62638-2-pkshih@realtek.com
2022-04-23 15:44:49 +03:00