Commit e6dd230a authored by Larry Finger's avatar Larry Finger Committed by Kalle Valo

rtlwifi: rtl8723be Rename RT_TRACE to rtl_dbg

Change the misleading macro name to one that is more descriptive for
rtl8723be. Changes suggested by ckeckpatch.pl have been made.
Signed-off-by: default avatarLarry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/20200723204244.24457-13-Larry.Finger@lwfinger.net
parent 8f11dad4
...@@ -225,9 +225,9 @@ static void rtl8723be_dm_init_txpower_tracking(struct ieee80211_hw *hw) ...@@ -225,9 +225,9 @@ static void rtl8723be_dm_init_txpower_tracking(struct ieee80211_hw *hw)
rtlpriv->dm.delta_power_index_last[RF90_PATH_A] = 0; rtlpriv->dm.delta_power_index_last[RF90_PATH_A] = 0;
rtlpriv->dm.power_index_offset[RF90_PATH_A] = 0; rtlpriv->dm.power_index_offset[RF90_PATH_A] = 0;
RT_TRACE(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD, rtl_dbg(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD,
" rtlpriv->dm.txpower_tracking = %d\n", "rtlpriv->dm.txpower_tracking = %d\n",
rtlpriv->dm.txpower_tracking); rtlpriv->dm.txpower_tracking);
} }
static void rtl8723be_dm_init_dynamic_atc_switch(struct ieee80211_hw *hw) static void rtl8723be_dm_init_dynamic_atc_switch(struct ieee80211_hw *hw)
...@@ -265,33 +265,33 @@ static void rtl8723be_dm_find_minimum_rssi(struct ieee80211_hw *hw) ...@@ -265,33 +265,33 @@ static void rtl8723be_dm_find_minimum_rssi(struct ieee80211_hw *hw)
if ((mac->link_state < MAC80211_LINKED) && if ((mac->link_state < MAC80211_LINKED) &&
(rtlpriv->dm.entry_min_undec_sm_pwdb == 0)) { (rtlpriv->dm.entry_min_undec_sm_pwdb == 0)) {
rtl_dm_dig->min_undec_pwdb_for_dm = 0; rtl_dm_dig->min_undec_pwdb_for_dm = 0;
RT_TRACE(rtlpriv, COMP_BB_POWERSAVING, DBG_LOUD, rtl_dbg(rtlpriv, COMP_BB_POWERSAVING, DBG_LOUD,
"Not connected to any\n"); "Not connected to any\n");
} }
if (mac->link_state >= MAC80211_LINKED) { if (mac->link_state >= MAC80211_LINKED) {
if (mac->opmode == NL80211_IFTYPE_AP || if (mac->opmode == NL80211_IFTYPE_AP ||
mac->opmode == NL80211_IFTYPE_ADHOC) { mac->opmode == NL80211_IFTYPE_ADHOC) {
rtl_dm_dig->min_undec_pwdb_for_dm = rtl_dm_dig->min_undec_pwdb_for_dm =
rtlpriv->dm.entry_min_undec_sm_pwdb; rtlpriv->dm.entry_min_undec_sm_pwdb;
RT_TRACE(rtlpriv, COMP_BB_POWERSAVING, DBG_LOUD, rtl_dbg(rtlpriv, COMP_BB_POWERSAVING, DBG_LOUD,
"AP Client PWDB = 0x%lx\n", "AP Client PWDB = 0x%lx\n",
rtlpriv->dm.entry_min_undec_sm_pwdb); rtlpriv->dm.entry_min_undec_sm_pwdb);
} else { } else {
rtl_dm_dig->min_undec_pwdb_for_dm = rtl_dm_dig->min_undec_pwdb_for_dm =
rtlpriv->dm.undec_sm_pwdb; rtlpriv->dm.undec_sm_pwdb;
RT_TRACE(rtlpriv, COMP_BB_POWERSAVING, DBG_LOUD, rtl_dbg(rtlpriv, COMP_BB_POWERSAVING, DBG_LOUD,
"STA Default Port PWDB = 0x%x\n", "STA Default Port PWDB = 0x%x\n",
rtl_dm_dig->min_undec_pwdb_for_dm); rtl_dm_dig->min_undec_pwdb_for_dm);
} }
} else { } else {
rtl_dm_dig->min_undec_pwdb_for_dm = rtl_dm_dig->min_undec_pwdb_for_dm =
rtlpriv->dm.entry_min_undec_sm_pwdb; rtlpriv->dm.entry_min_undec_sm_pwdb;
RT_TRACE(rtlpriv, COMP_BB_POWERSAVING, DBG_LOUD, rtl_dbg(rtlpriv, COMP_BB_POWERSAVING, DBG_LOUD,
"AP Ext Port or disconnect PWDB = 0x%x\n", "AP Ext Port or disconnect PWDB = 0x%x\n",
rtl_dm_dig->min_undec_pwdb_for_dm); rtl_dm_dig->min_undec_pwdb_for_dm);
} }
RT_TRACE(rtlpriv, COMP_DIG, DBG_LOUD, "MinUndecoratedPWDBForDM =%d\n", rtl_dbg(rtlpriv, COMP_DIG, DBG_LOUD, "MinUndecoratedPWDBForDM =%d\n",
rtl_dm_dig->min_undec_pwdb_for_dm); rtl_dm_dig->min_undec_pwdb_for_dm);
} }
static void rtl8723be_dm_check_rssi_monitor(struct ieee80211_hw *hw) static void rtl8723be_dm_check_rssi_monitor(struct ieee80211_hw *hw)
...@@ -421,7 +421,7 @@ static void rtl8723be_dm_dig(struct ieee80211_hw *hw) ...@@ -421,7 +421,7 @@ static void rtl8723be_dm_dig(struct ieee80211_hw *hw)
} else { } else {
dm_digtable->rx_gain_max = dm_dig_max; dm_digtable->rx_gain_max = dm_dig_max;
dig_min_0 = dm_dig_min; dig_min_0 = dm_dig_min;
RT_TRACE(rtlpriv, COMP_DIG, DBG_LOUD, "no link\n"); rtl_dbg(rtlpriv, COMP_DIG, DBG_LOUD, "no link\n");
} }
if (rtlpriv->falsealm_cnt.cnt_all > 10000) { if (rtlpriv->falsealm_cnt.cnt_all > 10000) {
...@@ -576,18 +576,18 @@ static void rtl8723be_dm_false_alarm_counter_statistics( ...@@ -576,18 +576,18 @@ static void rtl8723be_dm_false_alarm_counter_statistics(
rtl_set_bbreg(hw, DM_REG_CCK_FA_RST_11N, BIT(15) | BIT(14), 0); rtl_set_bbreg(hw, DM_REG_CCK_FA_RST_11N, BIT(15) | BIT(14), 0);
rtl_set_bbreg(hw, DM_REG_CCK_FA_RST_11N, BIT(15) | BIT(14), 2); rtl_set_bbreg(hw, DM_REG_CCK_FA_RST_11N, BIT(15) | BIT(14), 2);
RT_TRACE(rtlpriv, COMP_DIG, DBG_TRACE, rtl_dbg(rtlpriv, COMP_DIG, DBG_TRACE,
"cnt_parity_fail = %d, cnt_rate_illegal = %d, cnt_crc8_fail = %d, cnt_mcs_fail = %d\n", "cnt_parity_fail = %d, cnt_rate_illegal = %d, cnt_crc8_fail = %d, cnt_mcs_fail = %d\n",
falsealm_cnt->cnt_parity_fail, falsealm_cnt->cnt_parity_fail,
falsealm_cnt->cnt_rate_illegal, falsealm_cnt->cnt_rate_illegal,
falsealm_cnt->cnt_crc8_fail, falsealm_cnt->cnt_crc8_fail,
falsealm_cnt->cnt_mcs_fail); falsealm_cnt->cnt_mcs_fail);
RT_TRACE(rtlpriv, COMP_DIG, DBG_TRACE, rtl_dbg(rtlpriv, COMP_DIG, DBG_TRACE,
"cnt_ofdm_fail = %x, cnt_cck_fail = %x, cnt_all = %x\n", "cnt_ofdm_fail = %x, cnt_cck_fail = %x, cnt_all = %x\n",
falsealm_cnt->cnt_ofdm_fail, falsealm_cnt->cnt_ofdm_fail,
falsealm_cnt->cnt_cck_fail, falsealm_cnt->cnt_cck_fail,
falsealm_cnt->cnt_all); falsealm_cnt->cnt_all);
} }
static void rtl8723be_dm_dynamic_txpower(struct ieee80211_hw *hw) static void rtl8723be_dm_dynamic_txpower(struct ieee80211_hw *hw)
...@@ -747,18 +747,18 @@ static void rtl8723be_dm_txpower_tracking_callback_thermalmeter( ...@@ -747,18 +747,18 @@ static void rtl8723be_dm_txpower_tracking_callback_thermalmeter(
/*Initilization ( 7 steps in total )*/ /*Initilization ( 7 steps in total )*/
rtlpriv->dm.txpower_trackinginit = true; rtlpriv->dm.txpower_trackinginit = true;
RT_TRACE(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD, rtl_dbg(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD,
"rtl8723be_dm_txpower_tracking_callback_thermalmeter\n"); "%s\n", __func__);
thermalvalue = (u8)rtl_get_rfreg(hw, thermalvalue = (u8)rtl_get_rfreg(hw,
RF90_PATH_A, RF_T_METER, 0xfc00); RF90_PATH_A, RF_T_METER, 0xfc00);
if (!rtlpriv->dm.txpower_track_control || thermalvalue == 0 || if (!rtlpriv->dm.txpower_track_control || thermalvalue == 0 ||
rtlefuse->eeprom_thermalmeter == 0xFF) rtlefuse->eeprom_thermalmeter == 0xFF)
return; return;
RT_TRACE(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD, rtl_dbg(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD,
"Readback Thermal Meter = 0x%x pre thermal meter 0x%x eeprom_thermalmeter 0x%x\n", "Readback Thermal Meter = 0x%x pre thermal meter 0x%x eeprom_thermalmeter 0x%x\n",
thermalvalue, rtldm->thermalvalue, thermalvalue, rtldm->thermalvalue,
rtlefuse->eeprom_thermalmeter); rtlefuse->eeprom_thermalmeter);
/*3 Initialize ThermalValues of RFCalibrateInfo*/ /*3 Initialize ThermalValues of RFCalibrateInfo*/
if (!rtldm->thermalvalue) { if (!rtldm->thermalvalue) {
rtlpriv->dm.thermalvalue_lck = thermalvalue; rtlpriv->dm.thermalvalue_lck = thermalvalue;
...@@ -792,10 +792,10 @@ static void rtl8723be_dm_txpower_tracking_callback_thermalmeter( ...@@ -792,10 +792,10 @@ static void rtl8723be_dm_txpower_tracking_callback_thermalmeter(
(thermalvalue - rtlpriv->dm.thermalvalue_iqk) : (thermalvalue - rtlpriv->dm.thermalvalue_iqk) :
(rtlpriv->dm.thermalvalue_iqk - thermalvalue); (rtlpriv->dm.thermalvalue_iqk - thermalvalue);
RT_TRACE(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD, rtl_dbg(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD,
"Readback Thermal Meter = 0x%x pre thermal meter 0x%x eeprom_thermalmeter 0x%x delta 0x%x delta_lck 0x%x delta_iqk 0x%x\n", "Readback Thermal Meter = 0x%x pre thermal meter 0x%x eeprom_thermalmeter 0x%x delta 0x%x delta_lck 0x%x delta_iqk 0x%x\n",
thermalvalue, rtlpriv->dm.thermalvalue, thermalvalue, rtlpriv->dm.thermalvalue,
rtlefuse->eeprom_thermalmeter, delta, delta_lck, delta_iqk); rtlefuse->eeprom_thermalmeter, delta, delta_lck, delta_iqk);
/* 6 If necessary, do LCK.*/ /* 6 If necessary, do LCK.*/
if (delta_lck >= IQK_THRESHOLD) { if (delta_lck >= IQK_THRESHOLD) {
rtlpriv->dm.thermalvalue_lck = thermalvalue; rtlpriv->dm.thermalvalue_lck = thermalvalue;
...@@ -876,7 +876,7 @@ static void rtl8723be_dm_txpower_tracking_callback_thermalmeter( ...@@ -876,7 +876,7 @@ static void rtl8723be_dm_txpower_tracking_callback_thermalmeter(
} }
rtldm->txpowercount = 0; rtldm->txpowercount = 0;
RT_TRACE(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD, "end\n"); rtl_dbg(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD, "end\n");
} }
...@@ -890,13 +890,13 @@ void rtl8723be_dm_check_txpower_tracking(struct ieee80211_hw *hw) ...@@ -890,13 +890,13 @@ void rtl8723be_dm_check_txpower_tracking(struct ieee80211_hw *hw)
if (!rtlpriv->dm.tm_trigger) { if (!rtlpriv->dm.tm_trigger) {
rtl_set_rfreg(hw, RF90_PATH_A, RF_T_METER, BIT(17) | BIT(16), rtl_set_rfreg(hw, RF90_PATH_A, RF_T_METER, BIT(17) | BIT(16),
0x03); 0x03);
RT_TRACE(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD, rtl_dbg(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD,
"Trigger 8723be Thermal Meter!!\n"); "Trigger 8723be Thermal Meter!!\n");
rtlpriv->dm.tm_trigger = 1; rtlpriv->dm.tm_trigger = 1;
return; return;
} else { } else {
RT_TRACE(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD, rtl_dbg(rtlpriv, COMP_POWER_TRACKING, DBG_LOUD,
"Schedule TxPowerTracking !!\n"); "Schedule TxPowerTracking !!\n");
rtl8723be_dm_txpower_tracking_callback_thermalmeter(hw); rtl8723be_dm_txpower_tracking_callback_thermalmeter(hw);
rtlpriv->dm.tm_trigger = 0; rtlpriv->dm.tm_trigger = 0;
} }
...@@ -914,14 +914,14 @@ static void rtl8723be_dm_refresh_rate_adaptive_mask(struct ieee80211_hw *hw) ...@@ -914,14 +914,14 @@ static void rtl8723be_dm_refresh_rate_adaptive_mask(struct ieee80211_hw *hw)
struct ieee80211_sta *sta = NULL; struct ieee80211_sta *sta = NULL;
if (is_hal_stop(rtlhal)) { if (is_hal_stop(rtlhal)) {
RT_TRACE(rtlpriv, COMP_RATE, DBG_LOUD, rtl_dbg(rtlpriv, COMP_RATE, DBG_LOUD,
"driver is going to unload\n"); "driver is going to unload\n");
return; return;
} }
if (!rtlpriv->dm.useramask) { if (!rtlpriv->dm.useramask) {
RT_TRACE(rtlpriv, COMP_RATE, DBG_LOUD, rtl_dbg(rtlpriv, COMP_RATE, DBG_LOUD,
"driver does not control rate adaptive mask\n"); "driver does not control rate adaptive mask\n");
return; return;
} }
...@@ -949,14 +949,14 @@ static void rtl8723be_dm_refresh_rate_adaptive_mask(struct ieee80211_hw *hw) ...@@ -949,14 +949,14 @@ static void rtl8723be_dm_refresh_rate_adaptive_mask(struct ieee80211_hw *hw)
p_ra->ratr_state = DM_RATR_STA_LOW; p_ra->ratr_state = DM_RATR_STA_LOW;
if (p_ra->pre_ratr_state != p_ra->ratr_state) { if (p_ra->pre_ratr_state != p_ra->ratr_state) {
RT_TRACE(rtlpriv, COMP_RATE, DBG_LOUD, rtl_dbg(rtlpriv, COMP_RATE, DBG_LOUD,
"RSSI = %ld\n", "RSSI = %ld\n",
rtlpriv->dm.undec_sm_pwdb); rtlpriv->dm.undec_sm_pwdb);
RT_TRACE(rtlpriv, COMP_RATE, DBG_LOUD, rtl_dbg(rtlpriv, COMP_RATE, DBG_LOUD,
"RSSI_LEVEL = %d\n", p_ra->ratr_state); "RSSI_LEVEL = %d\n", p_ra->ratr_state);
RT_TRACE(rtlpriv, COMP_RATE, DBG_LOUD, rtl_dbg(rtlpriv, COMP_RATE, DBG_LOUD,
"PreState = %d, CurState = %d\n", "PreState = %d, CurState = %d\n",
p_ra->pre_ratr_state, p_ra->ratr_state); p_ra->pre_ratr_state, p_ra->ratr_state);
rcu_read_lock(); rcu_read_lock();
sta = rtl_find_sta(hw, mac->bssid); sta = rtl_find_sta(hw, mac->bssid);
...@@ -1073,8 +1073,8 @@ static void rtl8723be_dm_cck_packet_detection_thresh(struct ieee80211_hw *hw) ...@@ -1073,8 +1073,8 @@ static void rtl8723be_dm_cck_packet_detection_thresh(struct ieee80211_hw *hw)
dm_digtable->pre_cck_cca_thres = dm_digtable->cur_cck_cca_thres; dm_digtable->pre_cck_cca_thres = dm_digtable->cur_cck_cca_thres;
dm_digtable->cur_cck_cca_thres = cur_cck_cca_thresh; dm_digtable->cur_cck_cca_thres = cur_cck_cca_thresh;
RT_TRACE(rtlpriv, COMP_DIG, DBG_TRACE, rtl_dbg(rtlpriv, COMP_DIG, DBG_TRACE,
"CCK cca thresh hold =%x\n", dm_digtable->cur_cck_cca_thres); "CCK cca thresh hold =%x\n", dm_digtable->cur_cck_cca_thres);
} }
static void rtl8723be_dm_dynamic_edcca(struct ieee80211_hw *hw) static void rtl8723be_dm_dynamic_edcca(struct ieee80211_hw *hw)
...@@ -1121,8 +1121,8 @@ static void rtl8723be_dm_dynamic_atc_switch(struct ieee80211_hw *hw) ...@@ -1121,8 +1121,8 @@ static void rtl8723be_dm_dynamic_atc_switch(struct ieee80211_hw *hw)
} }
if (rtlpriv->cfg->ops->get_btc_status()) { if (rtlpriv->cfg->ops->get_btc_status()) {
if (!rtlpriv->btcoexist.btc_ops->btc_is_bt_disabled(rtlpriv)) { if (!rtlpriv->btcoexist.btc_ops->btc_is_bt_disabled(rtlpriv)) {
RT_TRACE(rtlpriv, COMP_BT_COEXIST, DBG_LOUD, rtl_dbg(rtlpriv, COMP_BT_COEXIST, DBG_LOUD,
"odm_DynamicATCSwitch(): Disable CFO tracking for BT!!\n"); "odm_DynamicATCSwitch(): Disable CFO tracking for BT!!\n");
return; return;
} }
} }
......
...@@ -41,22 +41,22 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id, ...@@ -41,22 +41,22 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id,
unsigned long flag; unsigned long flag;
u8 idx; u8 idx;
RT_TRACE(rtlpriv, COMP_CMD, DBG_LOUD, "come in\n"); rtl_dbg(rtlpriv, COMP_CMD, DBG_LOUD, "come in\n");
while (true) { while (true) {
spin_lock_irqsave(&rtlpriv->locks.h2c_lock, flag); spin_lock_irqsave(&rtlpriv->locks.h2c_lock, flag);
if (rtlhal->h2c_setinprogress) { if (rtlhal->h2c_setinprogress) {
RT_TRACE(rtlpriv, COMP_CMD, DBG_LOUD, rtl_dbg(rtlpriv, COMP_CMD, DBG_LOUD,
"H2C set in progress! Wait to set..element_id(%d).\n", "H2C set in progress! Wait to set..element_id(%d).\n",
element_id); element_id);
while (rtlhal->h2c_setinprogress) { while (rtlhal->h2c_setinprogress) {
spin_unlock_irqrestore(&rtlpriv->locks.h2c_lock, spin_unlock_irqrestore(&rtlpriv->locks.h2c_lock,
flag); flag);
h2c_waitcounter++; h2c_waitcounter++;
RT_TRACE(rtlpriv, COMP_CMD, DBG_LOUD, rtl_dbg(rtlpriv, COMP_CMD, DBG_LOUD,
"Wait 100 us (%d times)...\n", "Wait 100 us (%d times)...\n",
h2c_waitcounter); h2c_waitcounter);
udelay(100); udelay(100);
if (h2c_waitcounter > 1000) if (h2c_waitcounter > 1000)
...@@ -107,9 +107,9 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id, ...@@ -107,9 +107,9 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id,
while (!isfw_read) { while (!isfw_read) {
wait_h2c_limmit--; wait_h2c_limmit--;
if (wait_h2c_limmit == 0) { if (wait_h2c_limmit == 0) {
RT_TRACE(rtlpriv, COMP_CMD, DBG_LOUD, rtl_dbg(rtlpriv, COMP_CMD, DBG_LOUD,
"Waiting too long for FW read clear HMEBox(%d)!\n", "Waiting too long for FW read clear HMEBox(%d)!\n",
boxnum); boxnum);
break; break;
} }
...@@ -118,24 +118,24 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id, ...@@ -118,24 +118,24 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id,
isfw_read = _rtl8723be_check_fw_read_last_h2c(hw, isfw_read = _rtl8723be_check_fw_read_last_h2c(hw,
boxnum); boxnum);
u1b_tmp = rtl_read_byte(rtlpriv, 0x130); u1b_tmp = rtl_read_byte(rtlpriv, 0x130);
RT_TRACE(rtlpriv, COMP_CMD, DBG_LOUD, rtl_dbg(rtlpriv, COMP_CMD, DBG_LOUD,
"Waiting for FW read clear HMEBox(%d)!!! 0x130 = %2x\n", "Waiting for FW read clear HMEBox(%d)!!! 0x130 = %2x\n",
boxnum, u1b_tmp); boxnum, u1b_tmp);
} }
if (!isfw_read) { if (!isfw_read) {
RT_TRACE(rtlpriv, COMP_CMD, DBG_LOUD, rtl_dbg(rtlpriv, COMP_CMD, DBG_LOUD,
"Write H2C register BOX[%d] fail!!!!! Fw do not read.\n", "Write H2C register BOX[%d] fail!!!!! Fw do not read.\n",
boxnum); boxnum);
break; break;
} }
memset(boxcontent, 0, sizeof(boxcontent)); memset(boxcontent, 0, sizeof(boxcontent));
memset(boxextcontent, 0, sizeof(boxextcontent)); memset(boxextcontent, 0, sizeof(boxextcontent));
boxcontent[0] = element_id; boxcontent[0] = element_id;
RT_TRACE(rtlpriv, COMP_CMD, DBG_LOUD, rtl_dbg(rtlpriv, COMP_CMD, DBG_LOUD,
"Write element_id box_reg(%4x) = %2x\n", "Write element_id box_reg(%4x) = %2x\n",
box_reg, element_id); box_reg, element_id);
switch (cmd_len) { switch (cmd_len) {
case 1: case 1:
...@@ -182,16 +182,16 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id, ...@@ -182,16 +182,16 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id,
if (rtlhal->last_hmeboxnum == 4) if (rtlhal->last_hmeboxnum == 4)
rtlhal->last_hmeboxnum = 0; rtlhal->last_hmeboxnum = 0;
RT_TRACE(rtlpriv, COMP_CMD, DBG_LOUD, rtl_dbg(rtlpriv, COMP_CMD, DBG_LOUD,
"pHalData->last_hmeboxnum = %d\n", "pHalData->last_hmeboxnum = %d\n",
rtlhal->last_hmeboxnum); rtlhal->last_hmeboxnum);
} }
spin_lock_irqsave(&rtlpriv->locks.h2c_lock, flag); spin_lock_irqsave(&rtlpriv->locks.h2c_lock, flag);
rtlhal->h2c_setinprogress = false; rtlhal->h2c_setinprogress = false;
spin_unlock_irqrestore(&rtlpriv->locks.h2c_lock, flag); spin_unlock_irqrestore(&rtlpriv->locks.h2c_lock, flag);
RT_TRACE(rtlpriv, COMP_CMD, DBG_LOUD, "go out\n"); rtl_dbg(rtlpriv, COMP_CMD, DBG_LOUD, "go out\n");
} }
void rtl8723be_fill_h2c_cmd(struct ieee80211_hw *hw, u8 element_id, void rtl8723be_fill_h2c_cmd(struct ieee80211_hw *hw, u8 element_id,
...@@ -229,8 +229,8 @@ void rtl8723be_set_fw_pwrmode_cmd(struct ieee80211_hw *hw, u8 mode) ...@@ -229,8 +229,8 @@ void rtl8723be_set_fw_pwrmode_cmd(struct ieee80211_hw *hw, u8 mode)
if (bt_ctrl_lps) if (bt_ctrl_lps)
mode = (bt_lps_on ? FW_PS_MIN_MODE : FW_PS_ACTIVE_MODE); mode = (bt_lps_on ? FW_PS_MIN_MODE : FW_PS_ACTIVE_MODE);
RT_TRACE(rtlpriv, COMP_POWER, DBG_DMESG, "FW LPS mode = %d (coex:%d)\n", rtl_dbg(rtlpriv, COMP_POWER, DBG_DMESG, "FW LPS mode = %d (coex:%d)\n",
mode, bt_ctrl_lps); mode, bt_ctrl_lps);
switch (mode) { switch (mode) {
case FW_PS_MIN_MODE: case FW_PS_MIN_MODE:
...@@ -572,15 +572,15 @@ void rtl8723be_set_fw_rsvdpagepkt(struct ieee80211_hw *hw, ...@@ -572,15 +572,15 @@ void rtl8723be_set_fw_rsvdpagepkt(struct ieee80211_hw *hw,
b_dlok = true; b_dlok = true;
if (b_dlok) { if (b_dlok) {
RT_TRACE(rtlpriv, COMP_POWER, DBG_LOUD, rtl_dbg(rtlpriv, COMP_POWER, DBG_LOUD,
"Set RSVD page location to Fw.\n"); "Set RSVD page location to Fw.\n");
RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_DMESG, "H2C_RSVDPAGE:\n", RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_DMESG, "H2C_RSVDPAGE:\n",
u1rsvdpageloc, sizeof(u1rsvdpageloc)); u1rsvdpageloc, sizeof(u1rsvdpageloc));
rtl8723be_fill_h2c_cmd(hw, H2C_8723B_RSVDPAGE, rtl8723be_fill_h2c_cmd(hw, H2C_8723B_RSVDPAGE,
sizeof(u1rsvdpageloc), u1rsvdpageloc); sizeof(u1rsvdpageloc), u1rsvdpageloc);
} else } else
RT_TRACE(rtlpriv, COMP_ERR, DBG_WARNING, rtl_dbg(rtlpriv, COMP_ERR, DBG_WARNING,
"Set RSVD page location to Fw FAIL!!!!!!.\n"); "Set RSVD page location to Fw FAIL!!!!!!.\n");
} }
/*Should check FW support p2p or not.*/ /*Should check FW support p2p or not.*/
...@@ -607,11 +607,11 @@ void rtl8723be_set_p2p_ps_offload_cmd(struct ieee80211_hw *hw, ...@@ -607,11 +607,11 @@ void rtl8723be_set_p2p_ps_offload_cmd(struct ieee80211_hw *hw,
switch (p2p_ps_state) { switch (p2p_ps_state) {
case P2P_PS_DISABLE: case P2P_PS_DISABLE:
RT_TRACE(rtlpriv, COMP_FW, DBG_LOUD, "P2P_PS_DISABLE\n"); rtl_dbg(rtlpriv, COMP_FW, DBG_LOUD, "P2P_PS_DISABLE\n");
memset(p2p_ps_offload, 0, sizeof(*p2p_ps_offload)); memset(p2p_ps_offload, 0, sizeof(*p2p_ps_offload));
break; break;
case P2P_PS_ENABLE: case P2P_PS_ENABLE:
RT_TRACE(rtlpriv, COMP_FW, DBG_LOUD, "P2P_PS_ENABLE\n"); rtl_dbg(rtlpriv, COMP_FW, DBG_LOUD, "P2P_PS_ENABLE\n");
/* update CTWindow value. */ /* update CTWindow value. */
if (p2pinfo->ctwindow > 0) { if (p2pinfo->ctwindow > 0) {
p2p_ps_offload->ctwindow_en = 1; p2p_ps_offload->ctwindow_en = 1;
...@@ -668,11 +668,11 @@ void rtl8723be_set_p2p_ps_offload_cmd(struct ieee80211_hw *hw, ...@@ -668,11 +668,11 @@ void rtl8723be_set_p2p_ps_offload_cmd(struct ieee80211_hw *hw,
} }
break; break;
case P2P_PS_SCAN: case P2P_PS_SCAN:
RT_TRACE(rtlpriv, COMP_FW, DBG_LOUD, "P2P_PS_SCAN\n"); rtl_dbg(rtlpriv, COMP_FW, DBG_LOUD, "P2P_PS_SCAN\n");
p2p_ps_offload->discovery = 1; p2p_ps_offload->discovery = 1;
break; break;
case P2P_PS_SCAN_DONE: case P2P_PS_SCAN_DONE:
RT_TRACE(rtlpriv, COMP_FW, DBG_LOUD, "P2P_PS_SCAN_DONE\n"); rtl_dbg(rtlpriv, COMP_FW, DBG_LOUD, "P2P_PS_SCAN_DONE\n");
p2p_ps_offload->discovery = 0; p2p_ps_offload->discovery = 0;
p2pinfo->p2p_ps_state = P2P_PS_ENABLE; p2pinfo->p2p_ps_state = P2P_PS_ENABLE;
break; break;
......
...@@ -19,8 +19,8 @@ void rtl8723be_sw_led_on(struct ieee80211_hw *hw, struct rtl_led *pled) ...@@ -19,8 +19,8 @@ void rtl8723be_sw_led_on(struct ieee80211_hw *hw, struct rtl_led *pled)
u8 ledcfg; u8 ledcfg;
struct rtl_priv *rtlpriv = rtl_priv(hw); struct rtl_priv *rtlpriv = rtl_priv(hw);
RT_TRACE(rtlpriv, COMP_LED, DBG_LOUD, rtl_dbg(rtlpriv, COMP_LED, DBG_LOUD,
"LedAddr:%X ledpin=%d\n", REG_LEDCFG2, pled->ledpin); "LedAddr:%X ledpin=%d\n", REG_LEDCFG2, pled->ledpin);
switch (pled->ledpin) { switch (pled->ledpin) {
case LED_PIN_GPIO0: case LED_PIN_GPIO0:
...@@ -47,8 +47,8 @@ void rtl8723be_sw_led_off(struct ieee80211_hw *hw, struct rtl_led *pled) ...@@ -47,8 +47,8 @@ void rtl8723be_sw_led_off(struct ieee80211_hw *hw, struct rtl_led *pled)
struct rtl_priv *rtlpriv = rtl_priv(hw); struct rtl_priv *rtlpriv = rtl_priv(hw);
u8 ledcfg; u8 ledcfg;
RT_TRACE(rtlpriv, COMP_LED, DBG_LOUD, rtl_dbg(rtlpriv, COMP_LED, DBG_LOUD,
"LedAddr:%X ledpin=%d\n", REG_LEDCFG2, pled->ledpin); "LedAddr:%X ledpin=%d\n", REG_LEDCFG2, pled->ledpin);
ledcfg = rtl_read_byte(rtlpriv, REG_LEDCFG2); ledcfg = rtl_read_byte(rtlpriv, REG_LEDCFG2);
...@@ -127,6 +127,6 @@ void rtl8723be_led_control(struct ieee80211_hw *hw, ...@@ -127,6 +127,6 @@ void rtl8723be_led_control(struct ieee80211_hw *hw,
ledaction == LED_CTL_POWER_ON)) { ledaction == LED_CTL_POWER_ON)) {
return; return;
} }
RT_TRACE(rtlpriv, COMP_LED, DBG_LOUD, "ledaction %d,\n", ledaction); rtl_dbg(rtlpriv, COMP_LED, DBG_LOUD, "ledaction %d,\n", ledaction);
_rtl8723be_sw_led_control(hw, ledaction); _rtl8723be_sw_led_control(hw, ledaction);
} }
...@@ -478,12 +478,12 @@ static bool _rtl8723be_phy_rf6052_config_parafile(struct ieee80211_hw *hw) ...@@ -478,12 +478,12 @@ static bool _rtl8723be_phy_rf6052_config_parafile(struct ieee80211_hw *hw)
} }
if (!rtstatus) { if (!rtstatus) {
RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, rtl_dbg(rtlpriv, COMP_INIT, DBG_TRACE,
"Radio[%d] Fail!!\n", rfpath); "Radio[%d] Fail!!\n", rfpath);
return false; return false;
} }
} }
RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, "\n"); rtl_dbg(rtlpriv, COMP_INIT, DBG_TRACE, "\n");
return rtstatus; return rtstatus;
} }
...@@ -340,9 +340,9 @@ bool rtl8723be_rx_query_desc(struct ieee80211_hw *hw, ...@@ -340,9 +340,9 @@ bool rtl8723be_rx_query_desc(struct ieee80211_hw *hw,
else else
wake_match = 0; wake_match = 0;
if (wake_match) if (wake_match)
RT_TRACE(rtlpriv, COMP_RXDESC, DBG_LOUD, rtl_dbg(rtlpriv, COMP_RXDESC, DBG_LOUD,
"GGGGGGGGGGGGGet Wakeup Packet!! WakeMatch=%d\n", "GGGGGGGGGGGGGet Wakeup Packet!! WakeMatch=%d\n",
wake_match); wake_match);
rx_status->freq = hw->conf.chandef.chan->center_freq; rx_status->freq = hw->conf.chandef.chan->center_freq;
rx_status->band = hw->conf.chandef.chan->band; rx_status->band = hw->conf.chandef.chan->band;
...@@ -445,7 +445,7 @@ void rtl8723be_tx_fill_desc(struct ieee80211_hw *hw, ...@@ -445,7 +445,7 @@ void rtl8723be_tx_fill_desc(struct ieee80211_hw *hw,
mapping = pci_map_single(rtlpci->pdev, skb->data, skb->len, mapping = pci_map_single(rtlpci->pdev, skb->data, skb->len,
PCI_DMA_TODEVICE); PCI_DMA_TODEVICE);
if (pci_dma_mapping_error(rtlpci->pdev, mapping)) { if (pci_dma_mapping_error(rtlpci->pdev, mapping)) {
RT_TRACE(rtlpriv, COMP_SEND, DBG_TRACE, "DMA mapping error\n"); rtl_dbg(rtlpriv, COMP_SEND, DBG_TRACE, "DMA mapping error\n");
return; return;
} }
clear_pci_tx_desc_content(pdesc, sizeof(struct tx_desc_8723be)); clear_pci_tx_desc_content(pdesc, sizeof(struct tx_desc_8723be));
...@@ -459,9 +459,9 @@ void rtl8723be_tx_fill_desc(struct ieee80211_hw *hw, ...@@ -459,9 +459,9 @@ void rtl8723be_tx_fill_desc(struct ieee80211_hw *hw,
set_tx_desc_offset(pdesc, USB_HWDESC_HEADER_LEN + set_tx_desc_offset(pdesc, USB_HWDESC_HEADER_LEN +
EM_HDR_LEN); EM_HDR_LEN);
if (ptcb_desc->empkt_num) { if (ptcb_desc->empkt_num) {
RT_TRACE(rtlpriv, COMP_SEND, DBG_TRACE, rtl_dbg(rtlpriv, COMP_SEND, DBG_TRACE,
"Insert 8 byte.pTcb->EMPktNum:%d\n", "Insert 8 byte.pTcb->EMPktNum:%d\n",
ptcb_desc->empkt_num); ptcb_desc->empkt_num);
_rtl8723be_insert_emcontent(ptcb_desc, _rtl8723be_insert_emcontent(ptcb_desc,
(__le32 *)(skb->data)); (__le32 *)(skb->data));
} }
...@@ -551,8 +551,8 @@ void rtl8723be_tx_fill_desc(struct ieee80211_hw *hw, ...@@ -551,8 +551,8 @@ void rtl8723be_tx_fill_desc(struct ieee80211_hw *hw,
/* from being overwritten by retried packet rate.*/ /* from being overwritten by retried packet rate.*/
if (ieee80211_is_data_qos(fc)) { if (ieee80211_is_data_qos(fc)) {
if (mac->rdg_en) { if (mac->rdg_en) {
RT_TRACE(rtlpriv, COMP_SEND, DBG_TRACE, rtl_dbg(rtlpriv, COMP_SEND, DBG_TRACE,
"Enable RDG function.\n"); "Enable RDG function.\n");
set_tx_desc_rdg_enable(pdesc, 1); set_tx_desc_rdg_enable(pdesc, 1);
set_tx_desc_htc(pdesc, 1); set_tx_desc_htc(pdesc, 1);
} }
...@@ -583,7 +583,7 @@ void rtl8723be_tx_fill_desc(struct ieee80211_hw *hw, ...@@ -583,7 +583,7 @@ void rtl8723be_tx_fill_desc(struct ieee80211_hw *hw,
set_tx_desc_bmc(pdesc, 1); set_tx_desc_bmc(pdesc, 1);
} }
RT_TRACE(rtlpriv, COMP_SEND, DBG_TRACE, "\n"); rtl_dbg(rtlpriv, COMP_SEND, DBG_TRACE, "\n");
} }
void rtl8723be_tx_fill_cmddesc(struct ieee80211_hw *hw, u8 *pdesc8, void rtl8723be_tx_fill_cmddesc(struct ieee80211_hw *hw, u8 *pdesc8,
...@@ -600,8 +600,8 @@ void rtl8723be_tx_fill_cmddesc(struct ieee80211_hw *hw, u8 *pdesc8, ...@@ -600,8 +600,8 @@ void rtl8723be_tx_fill_cmddesc(struct ieee80211_hw *hw, u8 *pdesc8,
PCI_DMA_TODEVICE); PCI_DMA_TODEVICE);
if (pci_dma_mapping_error(rtlpci->pdev, mapping)) { if (pci_dma_mapping_error(rtlpci->pdev, mapping)) {
RT_TRACE(rtlpriv, COMP_SEND, DBG_TRACE, rtl_dbg(rtlpriv, COMP_SEND, DBG_TRACE,
"DMA mapping error\n"); "DMA mapping error\n");
return; return;
} }
clear_pci_tx_desc_content(pdesc, TX_DESC_SIZE); clear_pci_tx_desc_content(pdesc, TX_DESC_SIZE);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment