Lines Matching refs:rtlpriv
50 struct rtl_priv *rtlpriv = rtl_priv(hw); in rtl92c_phy_query_rf_reg() local
52 struct rtl_phy *rtlphy = &(rtlpriv->phy); in rtl92c_phy_query_rf_reg()
54 RT_TRACE(rtlpriv, COMP_RF, DBG_TRACE, in rtl92c_phy_query_rf_reg()
58 spin_lock(&rtlpriv->locks.rf_lock); in rtl92c_phy_query_rf_reg()
71 spin_unlock(&rtlpriv->locks.rf_lock); in rtl92c_phy_query_rf_reg()
73 RT_TRACE(rtlpriv, COMP_RF, DBG_TRACE, in rtl92c_phy_query_rf_reg()
82 struct rtl_priv *rtlpriv = rtl_priv(hw); in rtl92c_phy_mac_config() local
88 rtl_write_byte(rtlpriv, 0x14, 0x71); in rtl92c_phy_mac_config()
90 rtl_write_byte(rtlpriv, 0x04CA, 0x0A); in rtl92c_phy_mac_config()
97 struct rtl_priv *rtlpriv = rtl_priv(hw); in rtl92c_phy_bb_config() local
103 regval = rtl_read_word(rtlpriv, REG_SYS_FUNC_EN); in rtl92c_phy_bb_config()
104 rtl_write_word(rtlpriv, REG_SYS_FUNC_EN, in rtl92c_phy_bb_config()
106 rtl_write_byte(rtlpriv, REG_AFE_PLL_CTRL, 0x83); in rtl92c_phy_bb_config()
107 rtl_write_byte(rtlpriv, REG_AFE_PLL_CTRL + 1, 0xdb); in rtl92c_phy_bb_config()
108 rtl_write_byte(rtlpriv, REG_RF_CTRL, RF_EN | RF_RSTB | RF_SDMRSTB); in rtl92c_phy_bb_config()
109 rtl_write_byte(rtlpriv, REG_SYS_FUNC_EN, in rtl92c_phy_bb_config()
112 rtl_write_byte(rtlpriv, REG_AFE_XTAL_CTRL + 1, 0x80); in rtl92c_phy_bb_config()
113 regvaldw = rtl_read_dword(rtlpriv, REG_LEDCFG0); in rtl92c_phy_bb_config()
114 rtl_write_dword(rtlpriv, REG_LEDCFG0, regvaldw | BIT(23)); in rtl92c_phy_bb_config()
124 struct rtl_priv *rtlpriv = rtl_priv(hw); in rtl92ce_phy_set_rf_reg() local
125 struct rtl_phy *rtlphy = &(rtlpriv->phy); in rtl92ce_phy_set_rf_reg()
128 RT_TRACE(rtlpriv, COMP_RF, DBG_TRACE, in rtl92ce_phy_set_rf_reg()
132 spin_lock(&rtlpriv->locks.rf_lock); in rtl92ce_phy_set_rf_reg()
159 spin_unlock(&rtlpriv->locks.rf_lock); in rtl92ce_phy_set_rf_reg()
161 RT_TRACE(rtlpriv, COMP_RF, DBG_TRACE, in rtl92ce_phy_set_rf_reg()
168 struct rtl_priv *rtlpriv = rtl_priv(hw); in _rtl92c_phy_config_mac_with_headerfile() local
173 RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, "Read Rtl819XMACPHY_Array\n"); in _rtl92c_phy_config_mac_with_headerfile()
176 RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, "Img:RTL8192CEMAC_2T_ARRAY\n"); in _rtl92c_phy_config_mac_with_headerfile()
178 rtl_write_byte(rtlpriv, ptrarray[i], (u8) ptrarray[i + 1]); in _rtl92c_phy_config_mac_with_headerfile()
189 struct rtl_priv *rtlpriv = rtl_priv(hw); in _rtl92ce_phy_config_bb_with_headerfile() local
209 RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, in _rtl92ce_phy_config_bb_with_headerfile()
219 RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, in _rtl92ce_phy_config_bb_with_headerfile()
231 struct rtl_priv *rtlpriv = rtl_priv(hw); in _rtl92ce_phy_config_bb_with_pgheaderfile() local
250 RT_TRACE(rtlpriv, COMP_SEND, DBG_TRACE, in _rtl92ce_phy_config_bb_with_pgheaderfile()
264 struct rtl_priv *rtlpriv = rtl_priv(hw); in rtl92c_phy_config_rf_with_headerfile() local
272 RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, in rtl92c_phy_config_rf_with_headerfile()
274 RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, in rtl92c_phy_config_rf_with_headerfile()
281 RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, in rtl92c_phy_config_rf_with_headerfile()
283 RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, in rtl92c_phy_config_rf_with_headerfile()
286 RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, "Radio No %x\n", rfpath); in rtl92c_phy_config_rf_with_headerfile()
303 RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, in rtl92c_phy_config_rf_with_headerfile()
307 RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, in rtl92c_phy_config_rf_with_headerfile()
318 struct rtl_priv *rtlpriv = rtl_priv(hw); in rtl92ce_phy_set_bw_mode_callback() local
320 struct rtl_phy *rtlphy = &(rtlpriv->phy); in rtl92ce_phy_set_bw_mode_callback()
325 RT_TRACE(rtlpriv, COMP_SCAN, DBG_TRACE, "Switch to %s bandwidth\n", in rtl92ce_phy_set_bw_mode_callback()
334 reg_bw_opmode = rtl_read_byte(rtlpriv, REG_BWOPMODE); in rtl92ce_phy_set_bw_mode_callback()
335 reg_prsr_rsc = rtl_read_byte(rtlpriv, REG_RRSR + 2); in rtl92ce_phy_set_bw_mode_callback()
340 rtl_write_byte(rtlpriv, REG_BWOPMODE, reg_bw_opmode); in rtl92ce_phy_set_bw_mode_callback()
344 rtl_write_byte(rtlpriv, REG_BWOPMODE, reg_bw_opmode); in rtl92ce_phy_set_bw_mode_callback()
347 rtl_write_byte(rtlpriv, REG_RRSR + 2, reg_prsr_rsc); in rtl92ce_phy_set_bw_mode_callback()
350 RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, in rtl92ce_phy_set_bw_mode_callback()
375 RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, in rtl92ce_phy_set_bw_mode_callback()
381 RT_TRACE(rtlpriv, COMP_SCAN, DBG_TRACE, "<==\n"); in rtl92ce_phy_set_bw_mode_callback()
388 struct rtl_priv *rtlpriv = rtl_priv(hw); in _rtl92ce_phy_lc_calibrate() local
390 tmpreg = rtl_read_byte(rtlpriv, 0xd03); in _rtl92ce_phy_lc_calibrate()
393 rtl_write_byte(rtlpriv, 0xd03, tmpreg & 0x8F); in _rtl92ce_phy_lc_calibrate()
395 rtl_write_byte(rtlpriv, REG_TXPAUSE, 0xFF); in _rtl92ce_phy_lc_calibrate()
418 rtl_write_byte(rtlpriv, 0xd03, tmpreg); in _rtl92ce_phy_lc_calibrate()
425 rtl_write_byte(rtlpriv, REG_TXPAUSE, 0x00); in _rtl92ce_phy_lc_calibrate()
433 struct rtl_priv *rtlpriv = rtl_priv(hw); in _rtl92ce_phy_set_rf_sleep() local
435 rtl_write_byte(rtlpriv, REG_TXPAUSE, 0xFF); in _rtl92ce_phy_set_rf_sleep()
437 rtl_write_byte(rtlpriv, REG_APSD_CTRL, 0x40); in _rtl92ce_phy_set_rf_sleep()
440 rtl_write_byte(rtlpriv, REG_APSD_CTRL, 0x0); in _rtl92ce_phy_set_rf_sleep()
442 rtl_write_byte(rtlpriv, REG_APSD_CTRL, 0x40); in _rtl92ce_phy_set_rf_sleep()
447 rtl_write_byte(rtlpriv, REG_APSD_CTRL, 0x00); in _rtl92ce_phy_set_rf_sleep()
448 rtl_write_byte(rtlpriv, REG_SYS_FUNC_EN, 0xE2); in _rtl92ce_phy_set_rf_sleep()
449 rtl_write_byte(rtlpriv, REG_SYS_FUNC_EN, 0xE3); in _rtl92ce_phy_set_rf_sleep()
450 rtl_write_byte(rtlpriv, REG_TXPAUSE, 0x00); in _rtl92ce_phy_set_rf_sleep()
451 RT_TRACE(rtlpriv, COMP_POWER, DBG_TRACE, in _rtl92ce_phy_set_rf_sleep()
455 rtl_write_byte(rtlpriv, REG_SYS_FUNC_EN, 0xE2); in _rtl92ce_phy_set_rf_sleep()
456 rtl_write_byte(rtlpriv, REG_SPS0_CTRL, 0x22); in _rtl92ce_phy_set_rf_sleep()
462 struct rtl_priv *rtlpriv = rtl_priv(hw); in _rtl92ce_phy_set_rf_power_state() local
478 RT_TRACE(rtlpriv, COMP_RF, DBG_DMESG, in _rtl92ce_phy_set_rf_power_state()
485 RT_TRACE(rtlpriv, COMP_RF, DBG_DMESG, in _rtl92ce_phy_set_rf_power_state()
494 rtlpriv->cfg->ops->led_control(hw, in _rtl92ce_phy_set_rf_power_state()
497 rtlpriv->cfg->ops->led_control(hw, in _rtl92ce_phy_set_rf_power_state()
504 RT_TRACE(rtlpriv, COMP_RF, DBG_DMESG, in _rtl92ce_phy_set_rf_power_state()
510 rtlpriv->cfg->ops->led_control(hw, in _rtl92ce_phy_set_rf_power_state()
513 rtlpriv->cfg->ops->led_control(hw, in _rtl92ce_phy_set_rf_power_state()
530 RT_TRACE(rtlpriv, COMP_ERR, DBG_WARNING, in _rtl92ce_phy_set_rf_power_state()
539 RT_TRACE(rtlpriv, COMP_ERR, DBG_WARNING, in _rtl92ce_phy_set_rf_power_state()
547 RT_TRACE(rtlpriv, COMP_RF, DBG_DMESG, in _rtl92ce_phy_set_rf_power_state()
556 RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, in _rtl92ce_phy_set_rf_power_state()