Commit 4e2b4378 authored by Larry Finger's avatar Larry Finger Committed by Kalle Valo

rtlwifi: rtl8723be: Remove all instances of DBG_EMERG

This is a step toward eliminating the RT_TRACE macros. Those calls that
have DBG_EMERG as the level are always logged, and they represent error
conditions, thus they are replaced with pr_err().
Signed-off-by: default avatarLarry Finger <Larry.Finger@lwfinger.net>
Cc: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
parent 004a1e16
...@@ -97,8 +97,7 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id, ...@@ -97,8 +97,7 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id,
while (!bwrite_sucess) { while (!bwrite_sucess) {
wait_writeh2c_limmit--; wait_writeh2c_limmit--;
if (wait_writeh2c_limmit == 0) { if (wait_writeh2c_limmit == 0) {
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("Write H2C fail because no trigger for FW INT!\n");
"Write H2C fail because no trigger for FW INT!\n");
break; break;
} }
...@@ -121,8 +120,8 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id, ...@@ -121,8 +120,8 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id,
box_extreg = REG_HMEBOX_EXT_3; box_extreg = REG_HMEBOX_EXT_3;
break; break;
default: default:
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("switch case %#x not processed\n",
"switch case %#x not processed\n", boxnum); boxnum);
break; break;
} }
...@@ -194,8 +193,8 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id, ...@@ -194,8 +193,8 @@ static void _rtl8723be_fill_h2c_command(struct ieee80211_hw *hw, u8 element_id,
} }
break; break;
default: default:
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("switch case %#x not processed\n",
"switch case %#x not processed\n", cmd_len); cmd_len);
break; break;
} }
......
...@@ -747,8 +747,7 @@ static bool _rtl8723be_llt_write(struct ieee80211_hw *hw, u32 address, u32 data) ...@@ -747,8 +747,7 @@ static bool _rtl8723be_llt_write(struct ieee80211_hw *hw, u32 address, u32 data)
break; break;
if (count > POLLING_LLT_THRESHOLD) { if (count > POLLING_LLT_THRESHOLD) {
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("Failed to polling write LLT done at address %d!\n",
"Failed to polling write LLT done at address %d!\n",
address); address);
status = false; status = false;
break; break;
...@@ -1383,7 +1382,7 @@ int rtl8723be_hw_init(struct ieee80211_hw *hw) ...@@ -1383,7 +1382,7 @@ int rtl8723be_hw_init(struct ieee80211_hw *hw)
} }
rtstatus = _rtl8723be_init_mac(hw); rtstatus = _rtl8723be_init_mac(hw);
if (!rtstatus) { if (!rtstatus) {
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, "Init MAC failed\n"); pr_err("Init MAC failed\n");
err = 1; err = 1;
goto exit; goto exit;
} }
...@@ -1532,8 +1531,7 @@ static int _rtl8723be_set_media_status(struct ieee80211_hw *hw, ...@@ -1532,8 +1531,7 @@ static int _rtl8723be_set_media_status(struct ieee80211_hw *hw,
"Set Network type to AP!\n"); "Set Network type to AP!\n");
break; break;
default: default:
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("Network type %d not support!\n", type);
"Network type %d not support!\n", type);
return 1; return 1;
} }
...@@ -2247,7 +2245,7 @@ void rtl8723be_read_eeprom_info(struct ieee80211_hw *hw) ...@@ -2247,7 +2245,7 @@ void rtl8723be_read_eeprom_info(struct ieee80211_hw *hw)
rtlefuse->autoload_failflag = false; rtlefuse->autoload_failflag = false;
_rtl8723be_read_adapter_info(hw, false); _rtl8723be_read_adapter_info(hw, false);
} else { } else {
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, "Autoload ERR!!\n"); pr_err("Autoload ERR!!\n");
} }
_rtl8723be_hal_customized_behavior(hw); _rtl8723be_hal_customized_behavior(hw);
} }
...@@ -2584,9 +2582,7 @@ void rtl8723be_set_key(struct ieee80211_hw *hw, u32 key_index, ...@@ -2584,9 +2582,7 @@ void rtl8723be_set_key(struct ieee80211_hw *hw, u32 key_index,
entry_id = rtl_cam_get_free_entry(hw, entry_id = rtl_cam_get_free_entry(hw,
p_macaddr); p_macaddr);
if (entry_id >= TOTAL_CAM_ENTRY) { if (entry_id >= TOTAL_CAM_ENTRY) {
RT_TRACE(rtlpriv, COMP_SEC, pr_err("Can not find free hw security cam entry\n");
DBG_EMERG,
"Can not find free hw security cam entry\n");
return; return;
} }
} else { } else {
......
...@@ -57,8 +57,8 @@ void rtl8723be_sw_led_on(struct ieee80211_hw *hw, struct rtl_led *pled) ...@@ -57,8 +57,8 @@ void rtl8723be_sw_led_on(struct ieee80211_hw *hw, struct rtl_led *pled)
rtl_write_byte(rtlpriv, REG_LEDCFG1, ledcfg & 0x10); rtl_write_byte(rtlpriv, REG_LEDCFG1, ledcfg & 0x10);
break; break;
default: default:
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("switch case %#x not processed\n",
"switch case %#x not processed\n", pled->ledpin); pled->ledpin);
break; break;
} }
pled->ledon = true; pled->ledon = true;
...@@ -99,8 +99,8 @@ void rtl8723be_sw_led_off(struct ieee80211_hw *hw, struct rtl_led *pled) ...@@ -99,8 +99,8 @@ void rtl8723be_sw_led_off(struct ieee80211_hw *hw, struct rtl_led *pled)
break; break;
default: default:
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("switch case %#x not processed\n",
"switch case %#x not processed\n", pled->ledpin); pled->ledpin);
break; break;
} }
pled->ledon = false; pled->ledon = false;
......
...@@ -467,7 +467,7 @@ static bool _rtl8723be_phy_bb8723b_config_parafile(struct ieee80211_hw *hw) ...@@ -467,7 +467,7 @@ static bool _rtl8723be_phy_bb8723b_config_parafile(struct ieee80211_hw *hw)
rtstatus = _rtl8723be_phy_config_bb_with_headerfile(hw, rtstatus = _rtl8723be_phy_config_bb_with_headerfile(hw,
BASEBAND_CONFIG_PHY_REG); BASEBAND_CONFIG_PHY_REG);
if (!rtstatus) { if (!rtstatus) {
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, "Write BB Reg Fail!!\n"); pr_err("Write BB Reg Fail!!\n");
return false; return false;
} }
_rtl8723be_phy_init_tx_power_by_rate(hw); _rtl8723be_phy_init_tx_power_by_rate(hw);
...@@ -478,13 +478,13 @@ static bool _rtl8723be_phy_bb8723b_config_parafile(struct ieee80211_hw *hw) ...@@ -478,13 +478,13 @@ static bool _rtl8723be_phy_bb8723b_config_parafile(struct ieee80211_hw *hw)
} }
phy_txpower_by_rate_config(hw); phy_txpower_by_rate_config(hw);
if (!rtstatus) { if (!rtstatus) {
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, "BB_PG Reg Fail!!\n"); pr_err("BB_PG Reg Fail!!\n");
return false; return false;
} }
rtstatus = _rtl8723be_phy_config_bb_with_headerfile(hw, rtstatus = _rtl8723be_phy_config_bb_with_headerfile(hw,
BASEBAND_CONFIG_AGC_TAB); BASEBAND_CONFIG_AGC_TAB);
if (!rtstatus) { if (!rtstatus) {
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, "AGC Table Fail\n"); pr_err("AGC Table Fail\n");
return false; return false;
} }
rtlphy->cck_high_power = (bool)(rtl_get_bbreg(hw, rtlphy->cck_high_power = (bool)(rtl_get_bbreg(hw,
...@@ -1249,8 +1249,7 @@ void rtl8723be_phy_scan_operation_backup(struct ieee80211_hw *hw, u8 operation) ...@@ -1249,8 +1249,7 @@ void rtl8723be_phy_scan_operation_backup(struct ieee80211_hw *hw, u8 operation)
(u8 *)&iotype); (u8 *)&iotype);
break; break;
default: default:
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("Unknown Scan Backup operation.\n");
"Unknown Scan Backup operation.\n");
break; break;
} }
} }
...@@ -1291,8 +1290,8 @@ void rtl8723be_phy_set_bw_mode_callback(struct ieee80211_hw *hw) ...@@ -1291,8 +1290,8 @@ void rtl8723be_phy_set_bw_mode_callback(struct ieee80211_hw *hw)
rtl_write_byte(rtlpriv, REG_RRSR + 2, reg_prsr_rsc); rtl_write_byte(rtlpriv, REG_RRSR + 2, reg_prsr_rsc);
break; break;
default: default:
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("unknown bandwidth: %#X\n",
"unknown bandwidth: %#X\n", rtlphy->current_chan_bw); rtlphy->current_chan_bw);
break; break;
} }
...@@ -1316,8 +1315,8 @@ void rtl8723be_phy_set_bw_mode_callback(struct ieee80211_hw *hw) ...@@ -1316,8 +1315,8 @@ void rtl8723be_phy_set_bw_mode_callback(struct ieee80211_hw *hw)
HAL_PRIME_CHNL_OFFSET_LOWER) ? 2 : 1); HAL_PRIME_CHNL_OFFSET_LOWER) ? 2 : 1);
break; break;
default: default:
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("unknown bandwidth: %#X\n",
"unknown bandwidth: %#X\n", rtlphy->current_chan_bw); rtlphy->current_chan_bw);
break; break;
} }
rtl8723be_phy_rf6052_set_bandwidth(hw, rtlphy->current_chan_bw); rtl8723be_phy_rf6052_set_bandwidth(hw, rtlphy->current_chan_bw);
...@@ -1462,8 +1461,8 @@ static bool _rtl8723be_phy_sw_chnl_step_by_step(struct ieee80211_hw *hw, ...@@ -1462,8 +1461,8 @@ static bool _rtl8723be_phy_sw_chnl_step_by_step(struct ieee80211_hw *hw,
currentcmd = &postcommoncmd[*step]; currentcmd = &postcommoncmd[*step];
break; break;
default: default:
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("Invalid 'stage' = %d, Check it!\n",
"Invalid 'stage' = %d, Check it!\n", *stage); *stage);
return true; return true;
} }
......
...@@ -51,8 +51,7 @@ void rtl8723be_phy_rf6052_set_bandwidth(struct ieee80211_hw *hw, u8 bandwidth) ...@@ -51,8 +51,7 @@ void rtl8723be_phy_rf6052_set_bandwidth(struct ieee80211_hw *hw, u8 bandwidth)
rtlphy->rfreg_chnlval[0]); rtlphy->rfreg_chnlval[0]);
break; break;
default: default:
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("unknown bandwidth: %#X\n", bandwidth);
"unknown bandwidth: %#X\n", bandwidth);
break; break;
} }
} }
......
...@@ -179,8 +179,7 @@ int rtl8723be_init_sw_vars(struct ieee80211_hw *hw) ...@@ -179,8 +179,7 @@ int rtl8723be_init_sw_vars(struct ieee80211_hw *hw)
/* for firmware buf */ /* for firmware buf */
rtlpriv->rtlhal.pfirmware = vzalloc(0x8000); rtlpriv->rtlhal.pfirmware = vzalloc(0x8000);
if (!rtlpriv->rtlhal.pfirmware) { if (!rtlpriv->rtlhal.pfirmware) {
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("Can't alloc buffer for fw.\n");
"Can't alloc buffer for fw.\n");
return 1; return 1;
} }
...@@ -190,8 +189,7 @@ int rtl8723be_init_sw_vars(struct ieee80211_hw *hw) ...@@ -190,8 +189,7 @@ int rtl8723be_init_sw_vars(struct ieee80211_hw *hw)
rtlpriv->io.dev, GFP_KERNEL, hw, rtlpriv->io.dev, GFP_KERNEL, hw,
rtl_fw_cb); rtl_fw_cb);
if (err) { if (err) {
RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, pr_err("Failed to request firmware!\n");
"Failed to request firmware!\n");
return 1; return 1;
} }
return 0; return 0;
...@@ -273,7 +271,7 @@ static struct rtl_mod_params rtl8723be_mod_params = { ...@@ -273,7 +271,7 @@ static struct rtl_mod_params rtl8723be_mod_params = {
.fwctrl_lps = true, .fwctrl_lps = true,
.msi_support = false, .msi_support = false,
.disable_watchdog = false, .disable_watchdog = false,
.debug = DBG_EMERG, .debug = 0,
.ant_sel = 0, .ant_sel = 0,
}; };
......
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