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: Larry Finger
Cc: Ping-Ke Shih
---
V2 - eliminate some files that should not have been sent, and remove the
module name from the format. It is already specified by a pr_fmt().
---
.../net/wireless/realtek/rtlwifi/rtl8821ae/dm.c| 3 +-
.../net/wireless/realtek/rtlwifi/rtl8821ae/fw.c| 11 ++
.../net/wireless/realtek/rtlwifi/rtl8821ae/hw.c| 15 +++-
.../net/wireless/realtek/rtlwifi/rtl8821ae/phy.c | 43 --
.../net/wireless/realtek/rtlwifi/rtl8821ae/rf.c| 5 +--
.../net/wireless/realtek/rtlwifi/rtl8821ae/sw.c| 14 +++
6 files changed, 33 insertions(+), 58 deletions(-)
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/dm.c
b/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/dm.c
index bdfd444..32900c5 100644
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/dm.c
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/dm.c
@@ -604,8 +604,7 @@ static void rtl8821ae_dm_find_minimum_rssi(struct
ieee80211_hw *hw)
if ((mac->link_state < MAC80211_LINKED) &&
(rtlpriv->dm.entry_min_undec_sm_pwdb == 0)) {
rtl_dm_dig->min_undec_pwdb_for_dm = 0;
- RT_TRACE(rtlpriv, COMP_BB_POWERSAVING, DBG_LOUD,
-"Not connected to any\n");
+ pr_debug("rtl8821ae: Not connected to any AP\n");
}
if (mac->link_state >= MAC80211_LINKED) {
if (mac->opmode == NL80211_IFTYPE_AP ||
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c
b/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c
index c70face..602ac86 100644
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c
@@ -125,8 +125,7 @@ static void _rtl8821ae_write_fw(struct ieee80211_hw *hw,
remainsize = size % FW_8821AE_PAGE_SIZE;
if (pagenums > 8) {
- RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG,
-"Page numbers should not greater then 8\n");
+ pr_err("Page numbers should not greater then 8\n");
}
for (page = 0; page < pagenums; page++) {
@@ -162,8 +161,8 @@ static int _rtl8821ae_fw_free_to_go(struct ieee80211_hw *hw)
goto exit;
}
- RT_TRACE(rtlpriv, COMP_FW, DBG_EMERG,
-"Checksum report OK ! REG_MCUFWDL:0x%08x .\n", value32);
+ pr_err("Checksum report OK! REG_MCUFWDL:0x%08x\n",
+ value32);
value32 = rtl_read_dword(rtlpriv, REG_MCUFWDL);
value32 |= MCUFWDL_RDY;
@@ -186,9 +184,8 @@ static int _rtl8821ae_fw_free_to_go(struct ieee80211_hw *hw)
udelay(FW_8821AE_POLLING_DELAY);
} while (counter++ < FW_8821AE_POLLING_TIMEOUT_COUNT);
- RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG,
-"Polling FW ready fail!! REG_MCUFWDL:0x%08x .\n",
-value32);
+ pr_err("Polling FW ready fail!! REG_MCUFWDL:0x%08x .\n",
+ value32);
exit:
return err;
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/hw.c
b/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/hw.c
index b6dc2f3..3932a5d 100644
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/hw.c
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/hw.c
@@ -822,9 +822,8 @@ static bool _rtl8821ae_llt_write(struct ieee80211_hw *hw,
u32 address, u32 data)
break;
if (count > POLLING_LLT_THRESHOLD) {
- RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG,
-"Failed to polling write LLT done at address
%d!\n",
-address);
+ pr_err("Failed to polling write LLT done at address
%d!\n",
+ address);
status = false;
break;
}
@@ -1927,7 +1926,7 @@ int rtl8821ae_hw_init(struct ieee80211_hw *hw)
rtstatus = _rtl8821ae_init_mac(hw);
if (rtstatus != true) {
- RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, "Init MAC failed\n");
+ pr_err("Init MAC failed\n");
err = 1;
return err;
}
@@ -2174,8 +2173,7 @@ static int _rtl8821ae_set_media_status(struct
ieee80211_hw *hw,
"Set Network type to AP!\n");
break;
default:
- RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG,
-"Network type %d not support!\n", type);
+ pr_err("Network type %d not support!\n", type);
return 1;
}
@@ -3274,7 +3272,7 @@ void rtl8821ae_read_eeprom_info(struct ieee80211_hw *hw)
rtlefuse->autoload_failflag = false;