Lines Matching refs:rtwdev
114 static void rtw_phy_cck_pd_init(struct rtw_dev *rtwdev) in rtw_phy_cck_pd_init() argument
116 struct rtw_dm_info *dm_info = &rtwdev->dm_info; in rtw_phy_cck_pd_init()
127 void rtw_phy_init(struct rtw_dev *rtwdev) in rtw_phy_init() argument
129 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_init()
130 struct rtw_dm_info *dm_info = &rtwdev->dm_info; in rtw_phy_init()
144 dm_info->igi_history[0] = rtw_read32_mask(rtwdev, addr, mask); in rtw_phy_init()
145 rtw_phy_cck_pd_init(rtwdev); in rtw_phy_init()
148 void rtw_phy_dig_write(struct rtw_dev *rtwdev, u8 igi) in rtw_phy_dig_write() argument
150 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_dig_write()
151 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_dig_write()
158 rtw_write32_mask(rtwdev, addr, mask, igi); in rtw_phy_dig_write()
162 static void rtw_phy_stat_false_alarm(struct rtw_dev *rtwdev) in rtw_phy_stat_false_alarm() argument
164 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_stat_false_alarm()
166 chip->ops->false_alarm_statistics(rtwdev); in rtw_phy_stat_false_alarm()
193 struct rtw_dev *rtwdev; member
200 struct rtw_dev *rtwdev = iter_data->rtwdev; in rtw_phy_stat_rssi_iter() local
207 rtw_fw_send_rssi_info(rtwdev, si); in rtw_phy_stat_rssi_iter()
212 static void rtw_phy_stat_rssi(struct rtw_dev *rtwdev) in rtw_phy_stat_rssi() argument
214 struct rtw_dm_info *dm_info = &rtwdev->dm_info; in rtw_phy_stat_rssi()
217 data.rtwdev = rtwdev; in rtw_phy_stat_rssi()
219 rtw_iterate_stas_atomic(rtwdev, rtw_phy_stat_rssi_iter, &data); in rtw_phy_stat_rssi()
225 static void rtw_phy_statistics(struct rtw_dev *rtwdev) in rtw_phy_statistics() argument
227 rtw_phy_stat_rssi(rtwdev); in rtw_phy_statistics()
228 rtw_phy_stat_false_alarm(rtwdev); in rtw_phy_statistics()
387 static void rtw_phy_dig(struct rtw_dev *rtwdev) in rtw_phy_dig() argument
389 struct rtw_dm_info *dm_info = &rtwdev->dm_info; in rtw_phy_dig()
397 if (rtw_flag_check(rtwdev, RTW_FLAG_DIG_DISABLE)) in rtw_phy_dig()
403 linked = !!rtwdev->sta_cnt; in rtw_phy_dig()
437 rtw_phy_dig_write(rtwdev, cur_igi); in rtw_phy_dig()
442 struct rtw_dev *rtwdev = data; in rtw_phy_ra_info_update_iter() local
445 rtw_update_sta_info(rtwdev, si); in rtw_phy_ra_info_update_iter()
448 static void rtw_phy_ra_info_update(struct rtw_dev *rtwdev) in rtw_phy_ra_info_update() argument
450 if (rtwdev->watch_dog_cnt & 0x3) in rtw_phy_ra_info_update()
453 rtw_iterate_stas_atomic(rtwdev, rtw_phy_ra_info_update_iter, rtwdev); in rtw_phy_ra_info_update()
456 static void rtw_phy_dpk_track(struct rtw_dev *rtwdev) in rtw_phy_dpk_track() argument
458 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_dpk_track()
461 chip->ops->dpk_track(rtwdev); in rtw_phy_dpk_track()
468 static u8 rtw_phy_cck_pd_lv_unlink(struct rtw_dev *rtwdev) in rtw_phy_cck_pd_lv_unlink() argument
470 struct rtw_dm_info *dm_info = &rtwdev->dm_info; in rtw_phy_cck_pd_lv_unlink()
489 static u8 rtw_phy_cck_pd_lv_link(struct rtw_dev *rtwdev) in rtw_phy_cck_pd_lv_link() argument
491 struct rtw_dm_info *dm_info = &rtwdev->dm_info; in rtw_phy_cck_pd_lv_link()
510 static u8 rtw_phy_cck_pd_lv(struct rtw_dev *rtwdev) in rtw_phy_cck_pd_lv() argument
512 if (!rtw_is_assoc(rtwdev)) in rtw_phy_cck_pd_lv()
513 return rtw_phy_cck_pd_lv_unlink(rtwdev); in rtw_phy_cck_pd_lv()
515 return rtw_phy_cck_pd_lv_link(rtwdev); in rtw_phy_cck_pd_lv()
518 static void rtw_phy_cck_pd(struct rtw_dev *rtwdev) in rtw_phy_cck_pd() argument
520 struct rtw_dm_info *dm_info = &rtwdev->dm_info; in rtw_phy_cck_pd()
521 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_cck_pd()
525 if (rtwdev->hal.current_band_type != RTW_BAND_2G) in rtw_phy_cck_pd()
533 level = rtw_phy_cck_pd_lv(rtwdev); in rtw_phy_cck_pd()
539 chip->ops->cck_pd_set(rtwdev, level); in rtw_phy_cck_pd()
542 void rtw_phy_dynamic_mechanism(struct rtw_dev *rtwdev) in rtw_phy_dynamic_mechanism() argument
545 rtw_phy_statistics(rtwdev); in rtw_phy_dynamic_mechanism()
546 rtw_phy_dig(rtwdev); in rtw_phy_dynamic_mechanism()
547 rtw_phy_cck_pd(rtwdev); in rtw_phy_dynamic_mechanism()
548 rtw_phy_ra_info_update(rtwdev); in rtw_phy_dynamic_mechanism()
549 rtw_phy_dpk_track(rtwdev); in rtw_phy_dynamic_mechanism()
669 u32 rtw_phy_read_rf(struct rtw_dev *rtwdev, enum rtw_rf_path rf_path, in rtw_phy_read_rf() argument
672 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_read_rf()
673 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_read_rf()
678 rtw_err(rtwdev, "unsupported rf path (%d)\n", rf_path); in rtw_phy_read_rf()
686 val = rtw_read32_mask(rtwdev, direct_addr, mask); in rtw_phy_read_rf()
691 bool rtw_phy_write_rf_reg_sipi(struct rtw_dev *rtwdev, enum rtw_rf_path rf_path, in rtw_phy_write_rf_reg_sipi() argument
694 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_write_rf_reg_sipi()
695 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_write_rf_reg_sipi()
702 rtw_err(rtwdev, "unsupported rf path (%d)\n", rf_path); in rtw_phy_write_rf_reg_sipi()
710 old_data = rtw_phy_read_rf(rtwdev, rf_path, addr, RFREG_MASK); in rtw_phy_write_rf_reg_sipi()
713 rtw_err(rtwdev, "Write fail, rf is disabled\n"); in rtw_phy_write_rf_reg_sipi()
723 rtw_write32(rtwdev, sipi_addr[rf_path], data_and_addr); in rtw_phy_write_rf_reg_sipi()
730 bool rtw_phy_write_rf_reg(struct rtw_dev *rtwdev, enum rtw_rf_path rf_path, in rtw_phy_write_rf_reg() argument
733 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_write_rf_reg()
734 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_write_rf_reg()
739 rtw_err(rtwdev, "unsupported rf path (%d)\n", rf_path); in rtw_phy_write_rf_reg()
748 rtw_write32_mask(rtwdev, REG_RSV_CTRL, BITS_RFC_DIRECT, DISABLE_PI); in rtw_phy_write_rf_reg()
749 rtw_write32_mask(rtwdev, REG_WLRF1, BITS_RFC_DIRECT, DISABLE_PI); in rtw_phy_write_rf_reg()
752 rtw_write32_mask(rtwdev, direct_addr, mask, data); in rtw_phy_write_rf_reg()
757 rtw_write32_mask(rtwdev, REG_RSV_CTRL, BITS_RFC_DIRECT, ENABLE_PI); in rtw_phy_write_rf_reg()
758 rtw_write32_mask(rtwdev, REG_WLRF1, BITS_RFC_DIRECT, ENABLE_PI); in rtw_phy_write_rf_reg()
764 bool rtw_phy_write_rf_reg_mix(struct rtw_dev *rtwdev, enum rtw_rf_path rf_path, in rtw_phy_write_rf_reg_mix() argument
768 return rtw_phy_write_rf_reg(rtwdev, rf_path, addr, mask, data); in rtw_phy_write_rf_reg_mix()
770 return rtw_phy_write_rf_reg_sipi(rtwdev, rf_path, addr, mask, data); in rtw_phy_write_rf_reg_mix()
773 void rtw_phy_setup_phy_cond(struct rtw_dev *rtwdev, u32 pkg) in rtw_phy_setup_phy_cond() argument
775 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_setup_phy_cond()
776 struct rtw_efuse *efuse = &rtwdev->efuse; in rtw_phy_setup_phy_cond()
784 switch (rtw_hci_type(rtwdev)) { in rtw_phy_setup_phy_cond()
799 rtw_dbg(rtwdev, RTW_DBG_PHY, "phy cond=0x%08x\n", *((u32 *)&hal->phy_cond)); in rtw_phy_setup_phy_cond()
802 static bool check_positive(struct rtw_dev *rtwdev, struct rtw_phy_cond cond) in check_positive() argument
804 struct rtw_hal *hal = &rtwdev->hal; in check_positive()
822 void rtw_parse_tbl_phy_cond(struct rtw_dev *rtwdev, const struct rtw_table *tbl) in rtw_parse_tbl_phy_cond() argument
849 if (check_positive(rtwdev, pos_cond)) { in rtw_parse_tbl_phy_cond()
860 (*tbl->do_cfg)(rtwdev, tbl, p->cfg.addr, p->cfg.data); in rtw_parse_tbl_phy_cond()
867 static u8 tbl_to_dec_pwr_by_rate(struct rtw_dev *rtwdev, u32 hex, u8 i) in tbl_to_dec_pwr_by_rate() argument
869 if (rtwdev->chip->is_pwr_by_rate_dec) in tbl_to_dec_pwr_by_rate()
876 rtw_phy_get_rate_values_of_txpwr_by_rate(struct rtw_dev *rtwdev, in rtw_phy_get_rate_values_of_txpwr_by_rate() argument
890 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
900 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
915 tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
930 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
940 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
950 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
960 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
968 pwr_by_rate[i - 1] = tbl_to_dec_pwr_by_rate(rtwdev, in rtw_phy_get_rate_values_of_txpwr_by_rate()
981 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
993 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1005 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1017 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1029 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1041 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1053 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1065 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1077 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1089 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1101 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1113 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1125 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1137 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1149 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1161 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1171 pwr_by_rate[i] = tbl_to_dec_pwr_by_rate(rtwdev, val, i); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1175 rtw_warn(rtwdev, "invalid tx power index addr 0x%08x\n", addr); in rtw_phy_get_rate_values_of_txpwr_by_rate()
1180 static void rtw_phy_store_tx_power_by_rate(struct rtw_dev *rtwdev, in rtw_phy_store_tx_power_by_rate() argument
1184 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_store_tx_power_by_rate()
1192 rtw_phy_get_rate_values_of_txpwr_by_rate(rtwdev, regaddr, bitmask, data, in rtw_phy_store_tx_power_by_rate()
1212 void rtw_parse_tbl_bb_pg(struct rtw_dev *rtwdev, const struct rtw_table *tbl) in rtw_parse_tbl_bb_pg() argument
1224 rtw_phy_store_tx_power_by_rate(rtwdev, p->band, p->rf_path, in rtw_parse_tbl_bb_pg()
1262 static void rtw_phy_set_tx_power_limit(struct rtw_dev *rtwdev, u8 regd, u8 band, in rtw_phy_set_tx_power_limit() argument
1265 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_set_tx_power_limit()
1266 u8 max_power_index = rtwdev->chip->max_power_index; in rtw_phy_set_tx_power_limit()
1297 rtw_xref_5g_txpwr_lmt(struct rtw_dev *rtwdev, u8 regd, in rtw_xref_5g_txpwr_lmt() argument
1300 struct rtw_hal *hal = &rtwdev->hal; in rtw_xref_5g_txpwr_lmt()
1301 u8 max_power_index = rtwdev->chip->max_power_index; in rtw_xref_5g_txpwr_lmt()
1317 rtw_xref_txpwr_lmt_by_rs(struct rtw_dev *rtwdev, u8 regd, u8 bw, u8 ch_idx) in rtw_xref_txpwr_lmt_by_rs() argument
1327 rtw_xref_5g_txpwr_lmt(rtwdev, regd, bw, ch_idx, rs_ht, rs_vht); in rtw_xref_txpwr_lmt_by_rs()
1333 rtw_xref_5g_txpwr_lmt_by_ch(struct rtw_dev *rtwdev, u8 regd, u8 bw) in rtw_xref_5g_txpwr_lmt_by_ch() argument
1338 rtw_xref_txpwr_lmt_by_rs(rtwdev, regd, bw, ch_idx); in rtw_xref_5g_txpwr_lmt_by_ch()
1343 rtw_xref_txpwr_lmt_by_bw(struct rtw_dev *rtwdev, u8 regd) in rtw_xref_txpwr_lmt_by_bw() argument
1348 rtw_xref_5g_txpwr_lmt_by_ch(rtwdev, regd, bw); in rtw_xref_txpwr_lmt_by_bw()
1352 static void rtw_xref_txpwr_lmt(struct rtw_dev *rtwdev) in rtw_xref_txpwr_lmt() argument
1357 rtw_xref_txpwr_lmt_by_bw(rtwdev, regd); in rtw_xref_txpwr_lmt()
1360 void rtw_parse_tbl_txpwr_lmt(struct rtw_dev *rtwdev, in rtw_parse_tbl_txpwr_lmt() argument
1367 rtw_phy_set_tx_power_limit(rtwdev, p->regd, p->band, in rtw_parse_tbl_txpwr_lmt()
1371 rtw_xref_txpwr_lmt(rtwdev); in rtw_parse_tbl_txpwr_lmt()
1374 void rtw_phy_cfg_mac(struct rtw_dev *rtwdev, const struct rtw_table *tbl, in rtw_phy_cfg_mac() argument
1377 rtw_write8(rtwdev, addr, data); in rtw_phy_cfg_mac()
1380 void rtw_phy_cfg_agc(struct rtw_dev *rtwdev, const struct rtw_table *tbl, in rtw_phy_cfg_agc() argument
1383 rtw_write32(rtwdev, addr, data); in rtw_phy_cfg_agc()
1386 void rtw_phy_cfg_bb(struct rtw_dev *rtwdev, const struct rtw_table *tbl, in rtw_phy_cfg_bb() argument
1402 rtw_write32(rtwdev, addr, data); in rtw_phy_cfg_bb()
1405 void rtw_phy_cfg_rf(struct rtw_dev *rtwdev, const struct rtw_table *tbl, in rtw_phy_cfg_rf() argument
1413 rtw_write_rf(rtwdev, tbl->rf_path, addr, RFREG_MASK, data); in rtw_phy_cfg_rf()
1418 static void rtw_load_rfk_table(struct rtw_dev *rtwdev) in rtw_load_rfk_table() argument
1420 struct rtw_chip_info *chip = rtwdev->chip; in rtw_load_rfk_table()
1421 struct rtw_dpk_info *dpk_info = &rtwdev->dm_info.dpk_info; in rtw_load_rfk_table()
1426 rtw_write32_mask(rtwdev, 0x1e24, BIT(17), 0x1); in rtw_load_rfk_table()
1427 rtw_write32_mask(rtwdev, 0x1cd0, BIT(28), 0x1); in rtw_load_rfk_table()
1428 rtw_write32_mask(rtwdev, 0x1cd0, BIT(29), 0x1); in rtw_load_rfk_table()
1429 rtw_write32_mask(rtwdev, 0x1cd0, BIT(30), 0x1); in rtw_load_rfk_table()
1430 rtw_write32_mask(rtwdev, 0x1cd0, BIT(31), 0x0); in rtw_load_rfk_table()
1432 rtw_load_table(rtwdev, chip->rfk_init_tbl); in rtw_load_rfk_table()
1437 void rtw_phy_load_tables(struct rtw_dev *rtwdev) in rtw_phy_load_tables() argument
1439 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_load_tables()
1442 rtw_load_table(rtwdev, chip->mac_tbl); in rtw_phy_load_tables()
1443 rtw_load_table(rtwdev, chip->bb_tbl); in rtw_phy_load_tables()
1444 rtw_load_table(rtwdev, chip->agc_tbl); in rtw_phy_load_tables()
1445 rtw_load_rfk_table(rtwdev); in rtw_phy_load_tables()
1447 for (rf_path = 0; rf_path < rtwdev->hal.rf_path_num; rf_path++) { in rtw_phy_load_tables()
1451 rtw_load_table(rtwdev, tbl); in rtw_phy_load_tables()
1544 static s8 rtw_phy_get_dis_dpd_by_rate_diff(struct rtw_dev *rtwdev, u16 rate) in rtw_phy_get_dis_dpd_by_rate_diff() argument
1546 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_get_dis_dpd_by_rate_diff()
1575 static u8 rtw_phy_get_2g_tx_power_index(struct rtw_dev *rtwdev, in rtw_phy_get_2g_tx_power_index() argument
1580 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_get_2g_tx_power_index()
1622 static u8 rtw_phy_get_5g_tx_power_index(struct rtw_dev *rtwdev, in rtw_phy_get_5g_tx_power_index() argument
1627 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_get_5g_tx_power_index()
1676 static s8 rtw_phy_get_tx_power_limit(struct rtw_dev *rtwdev, u8 band, in rtw_phy_get_tx_power_limit() argument
1680 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_get_tx_power_limit()
1682 s8 power_limit = (s8)rtwdev->chip->max_power_index; in rtw_phy_get_tx_power_limit()
1734 return (s8)rtwdev->chip->max_power_index; in rtw_phy_get_tx_power_limit()
1737 void rtw_get_tx_power_params(struct rtw_dev *rtwdev, u8 path, u8 rate, u8 bw, in rtw_get_tx_power_params() argument
1740 struct rtw_hal *hal = &rtwdev->hal; in rtw_get_tx_power_params()
1747 pwr_idx = &rtwdev->efuse.txpwr_idx_table[path]; in rtw_get_tx_power_params()
1753 *base = rtw_phy_get_2g_tx_power_index(rtwdev, in rtw_get_tx_power_params()
1759 *base = rtw_phy_get_5g_tx_power_index(rtwdev, in rtw_get_tx_power_params()
1765 *limit = rtw_phy_get_tx_power_limit(rtwdev, band, bw, path, in rtw_get_tx_power_params()
1770 rtw_phy_get_tx_power_index(struct rtw_dev *rtwdev, u8 rf_path, u8 rate, in rtw_phy_get_tx_power_index() argument
1777 rtw_get_tx_power_params(rtwdev, rf_path, rate, bandwidth, in rtw_phy_get_tx_power_index()
1783 if (rtwdev->chip->en_dis_dpd) in rtw_phy_get_tx_power_index()
1784 offset += rtw_phy_get_dis_dpd_by_rate_diff(rtwdev, rate); in rtw_phy_get_tx_power_index()
1788 if (tx_power > rtwdev->chip->max_power_index) in rtw_phy_get_tx_power_index()
1789 tx_power = rtwdev->chip->max_power_index; in rtw_phy_get_tx_power_index()
1794 static void rtw_phy_set_tx_power_index_by_rs(struct rtw_dev *rtwdev, in rtw_phy_set_tx_power_index_by_rs() argument
1797 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_set_tx_power_index_by_rs()
1798 u8 regd = rtwdev->regd.txpwr_regd; in rtw_phy_set_tx_power_index_by_rs()
1814 pwr_idx = rtw_phy_get_tx_power_index(rtwdev, path, rate, in rtw_phy_set_tx_power_index_by_rs()
1825 static void rtw_phy_set_tx_power_level_by_path(struct rtw_dev *rtwdev, in rtw_phy_set_tx_power_level_by_path() argument
1828 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_set_tx_power_level_by_path()
1838 rtw_phy_set_tx_power_index_by_rs(rtwdev, ch, path, rs); in rtw_phy_set_tx_power_level_by_path()
1841 void rtw_phy_set_tx_power_level(struct rtw_dev *rtwdev, u8 channel) in rtw_phy_set_tx_power_level() argument
1843 struct rtw_chip_info *chip = rtwdev->chip; in rtw_phy_set_tx_power_level()
1844 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_set_tx_power_level()
1850 rtw_phy_set_tx_power_level_by_path(rtwdev, channel, path); in rtw_phy_set_tx_power_level()
1852 chip->ops->set_tx_power_index(rtwdev); in rtw_phy_set_tx_power_level()
1935 static void rtw_phy_init_tx_power_limit(struct rtw_dev *rtwdev, in rtw_phy_init_tx_power_limit() argument
1938 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_init_tx_power_limit()
1939 s8 max_power_index = (s8)rtwdev->chip->max_power_index; in rtw_phy_init_tx_power_limit()
1951 void rtw_phy_init_tx_power(struct rtw_dev *rtwdev) in rtw_phy_init_tx_power() argument
1953 struct rtw_hal *hal = &rtwdev->hal; in rtw_phy_init_tx_power()
1968 rtw_phy_init_tx_power_limit(rtwdev, regd, bw, in rtw_phy_init_tx_power()