rtlwifi: Standardize RT_PRINT_DATA macro and uses
authorJoe Perches <joe@perches.com>
Thu, 5 Jan 2012 03:40:40 +0000 (19:40 -0800)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 24 Jan 2012 19:06:06 +0000 (14:06 -0500)
Use a single printk(KERN_DEBUG to emit the header line
to avoid any possible output interleaving.

Remove unnecessary parentheses from the calling uses.
Standardize header arg without trailing \n or colon.
Fix a few pairwiase/pairwise typos.

Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 files changed:
drivers/net/wireless/rtlwifi/debug.h
drivers/net/wireless/rtlwifi/efuse.c
drivers/net/wireless/rtlwifi/rtl8192c/fw_common.c
drivers/net/wireless/rtlwifi/rtl8192ce/hw.c
drivers/net/wireless/rtlwifi/rtl8192ce/trx.c
drivers/net/wireless/rtlwifi/rtl8192cu/hw.c
drivers/net/wireless/rtlwifi/rtl8192cu/mac.c
drivers/net/wireless/rtlwifi/rtl8192cu/trx.c
drivers/net/wireless/rtlwifi/rtl8192de/fw.c
drivers/net/wireless/rtlwifi/rtl8192de/hw.c
drivers/net/wireless/rtlwifi/rtl8192de/trx.c
drivers/net/wireless/rtlwifi/rtl8192se/hw.c

index 802c491b3d86bbe20f31f094f5bc7995cc3fcd27..588986a1e21305c93f61fb9e8b695939fd371292 100644 (file)
@@ -189,10 +189,9 @@ do {                                                                       \
 do {                                                                   \
        if (unlikely(((_comp) & rtlpriv->dbg.global_debugcomponents) && \
                     (_level <= rtlpriv->dbg.global_debuglevel))) {     \
-               printk(KERN_DEBUG "%s: ", KBUILD_MODNAME);              \
-               pr_cont("In process \"%s\" (pid %i):",                  \
-                       current->comm, current->pid);                   \
-               printk(_titlestring);                                   \
+               printk(KERN_DEBUG "%s: In process \"%s\" (pid %i): %s\n", \
+                      KBUILD_MODNAME, current->comm, current->pid,     \
+                      _titlestring);                                   \
                print_hex_dump_bytes("", DUMP_PREFIX_NONE,              \
                                     _hexdata, _hexdatalen);            \
        }                                                               \
index ed1058b7158700c6eb65cc1f373472577b85ab1f..91fd3639d7372e68b5ca7ae60875854f573f2dc5 100644 (file)
@@ -478,7 +478,7 @@ bool efuse_shadow_update(struct ieee80211_hw *hw)
                               &rtlefuse->efuse_map[EFUSE_MODIFY_MAP][base],
                               8);
                        RT_PRINT_DATA(rtlpriv, COMP_INIT, DBG_LOUD,
-                                     ("U-efuse\n"), tmpdata, 8);
+                                     "U-efuse", tmpdata, 8);
 
                        if (!efuse_pg_packet_write(hw, (u8) offset, word_en,
                                                   tmpdata)) {
index 931d97979b04e3bcd26dbdfa1fdfa390be48db6e..5401b32733d32c767649464b3c42806ee74cb7ac 100644 (file)
@@ -570,7 +570,7 @@ void rtl92c_set_fw_pwrmode_cmd(struct ieee80211_hw *hw, u8 mode)
                                              ppsc->reg_max_lps_awakeintvl);
 
        RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_DMESG,
-                     "rtl92c_set_fw_rsvdpagepkt(): u1_h2c_set_pwrmode\n",
+                     "rtl92c_set_fw_rsvdpagepkt(): u1_h2c_set_pwrmode",
                      u1_h2c_set_pwrmode, 3);
        rtl92c_fill_h2c_cmd(hw, H2C_SETPWRMODE, 3, u1_h2c_set_pwrmode);
 
@@ -780,10 +780,10 @@ void rtl92c_set_fw_rsvdpagepkt(struct ieee80211_hw *hw, bool dl_finished)
        totalpacketlen = TOTAL_RESERVED_PKT_LEN;
 
        RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_LOUD,
-                     "rtl92c_set_fw_rsvdpagepkt(): HW_VAR_SET_TX_CMD: ALL\n",
+                     "rtl92c_set_fw_rsvdpagepkt(): HW_VAR_SET_TX_CMD: ALL",
                      &reserved_page_packet[0], totalpacketlen);
        RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_DMESG,
-                     "rtl92c_set_fw_rsvdpagepkt(): HW_VAR_SET_TX_CMD: ALL\n",
+                     "rtl92c_set_fw_rsvdpagepkt(): HW_VAR_SET_TX_CMD: ALL",
                      u1RsvdPageLoc, 3);
 
 
@@ -800,8 +800,7 @@ void rtl92c_set_fw_rsvdpagepkt(struct ieee80211_hw *hw, bool dl_finished)
                RT_TRACE(rtlpriv, COMP_POWER, DBG_LOUD,
                         ("Set RSVD page location to Fw.\n"));
                RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_DMESG,
-                               "H2C_RSVDPAGE:\n",
-                               u1RsvdPageLoc, 3);
+                             "H2C_RSVDPAGE", u1RsvdPageLoc, 3);
                rtl92c_fill_h2c_cmd(hw, H2C_RSVDPAGE,
                                    sizeof(u1RsvdPageLoc), u1RsvdPageLoc);
        } else
index a3deaefa788c1c30f630f57bdb12c6d09007d46d..2156378de1e890a84b2e858b7546c025a4a65441 100644 (file)
@@ -1570,7 +1570,7 @@ static void _rtl92ce_read_adapter_info(struct ieee80211_hw *hw)
                         ("RTL819X Not boot from eeprom, check it !!"));
        }
 
-       RT_PRINT_DATA(rtlpriv, COMP_INIT, DBG_DMESG, ("MAP\n"),
+       RT_PRINT_DATA(rtlpriv, COMP_INIT, DBG_DMESG, "MAP",
                      hwinfo, HWSET_MAX_SIZE);
 
        eeprom_id = *((u16 *)&hwinfo[0]);
@@ -2134,7 +2134,7 @@ void rtl92ce_set_key(struct ieee80211_hw *hw, u32 key_index,
                                 ("add one entry\n"));
                        if (is_pairwise) {
                                RT_PRINT_DATA(rtlpriv, COMP_SEC, DBG_LOUD,
-                                             "Pairwiase Key content :",
+                                             "Pairwise Key content",
                                              rtlpriv->sec.pairwise_key,
                                              rtlpriv->sec.
                                              key_len[PAIRWISE_KEYIDX]);
index 4fb5ae24dee07fc08819add09b6e7793298beff8..378bc56734642ac32045856cc1a747d91046e8f1 100644 (file)
@@ -821,8 +821,7 @@ void rtl92ce_tx_fill_cmddesc(struct ieee80211_hw *hw,
        }
 
        RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_LOUD,
-                     "H2C Tx Cmd Content\n",
-                     pdesc, TX_DESC_SIZE);
+                     "H2C Tx Cmd Content", pdesc, TX_DESC_SIZE);
 }
 
 void rtl92ce_set_desc(u8 *pdesc, bool istx, u8 desc_name, u8 *val)
index 124cf633861c3d6f061e44af9083f95a0a12b395..778c0e6e836bc4bf5fbc93e71054b89da16ca559 100644 (file)
@@ -496,7 +496,7 @@ static void _rtl92cu_read_adapter_info(struct ieee80211_hw *hw)
                RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG,
                         ("RTL819X Not boot from eeprom, check it !!"));
        }
-       RT_PRINT_DATA(rtlpriv, COMP_INIT, DBG_LOUD, ("MAP\n"),
+       RT_PRINT_DATA(rtlpriv, COMP_INIT, DBG_LOUD, "MAP",
                      hwinfo, HWSET_MAX_SIZE);
        eeprom_id = le16_to_cpu(*((__le16 *)&hwinfo[0]));
        if (eeprom_id != RTL8190_EEPROM_ID) {
index 9e0c8fcdf90fb60c1fb9370e3fe0c36d563f3da7..487ee908d7c5e92102e50de67be96ad8737c9b9e 100644 (file)
@@ -331,7 +331,7 @@ void rtl92c_set_key(struct ieee80211_hw *hw, u32 key_index,
                                 ("add one entry\n"));
                        if (is_pairwise) {
                                RT_PRINT_DATA(rtlpriv, COMP_SEC, DBG_LOUD,
-                                             "Pairwiase Key content :",
+                                             "Pairwise Key content",
                                              rtlpriv->sec.pairwise_key,
                                              rtlpriv->sec.
                                              key_len[PAIRWISE_KEYIDX]);
index b3cc7b9499927d3db75af87c0d1d2ebcd66e8b3b..128cfcd09fa988f8ab860d55573b8b76aaf2011c 100644 (file)
@@ -677,7 +677,7 @@ void rtl92cu_tx_fill_cmddesc(struct ieee80211_hw *hw,
                SET_TX_DESC_HWSEQ_EN(pdesc, 1);
                SET_TX_DESC_PKT_ID(pdesc, 8);
        }
-       RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_LOUD, "H2C Tx Cmd Content\n",
+       RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_LOUD, "H2C Tx Cmd Content",
                      pdesc, RTL_TX_DESC_SIZE);
 }
 
index 82f060bdbc0b7fa8b22b14b96c8b478c977758ee..db6972ffe503d34c09f7c2bc2f74f9bba68a0132 100644 (file)
@@ -565,7 +565,7 @@ void rtl92d_set_fw_pwrmode_cmd(struct ieee80211_hw *hw, u8 mode)
        SET_H2CCMD_PWRMODE_PARM_BCN_PASS_TIME(u1_h2c_set_pwrmode,
                                              ppsc->reg_max_lps_awakeintvl);
        RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_DMESG,
-                     "rtl92d_set_fw_rsvdpagepkt(): u1_h2c_set_pwrmode\n",
+                     "rtl92d_set_fw_rsvdpagepkt(): u1_h2c_set_pwrmode",
                      u1_h2c_set_pwrmode, 3);
        rtl92d_fill_h2c_cmd(hw, H2C_SETPWRMODE, 3, u1_h2c_set_pwrmode);
 }
@@ -757,10 +757,10 @@ void rtl92d_set_fw_rsvdpagepkt(struct ieee80211_hw *hw, bool dl_finished)
        SET_H2CCMD_RSVDPAGE_LOC_PROBE_RSP(u1RsvdPageLoc, PROBERSP_PG);
        totalpacketlen = TOTAL_RESERVED_PKT_LEN;
        RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_LOUD,
-                     "rtl92d_set_fw_rsvdpagepkt(): HW_VAR_SET_TX_CMD: ALL\n",
+                     "rtl92d_set_fw_rsvdpagepkt(): HW_VAR_SET_TX_CMD: ALL",
                      &reserved_page_packet[0], totalpacketlen);
        RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_DMESG,
-                     "rtl92d_set_fw_rsvdpagepkt(): HW_VAR_SET_TX_CMD: ALL\n",
+                     "rtl92d_set_fw_rsvdpagepkt(): HW_VAR_SET_TX_CMD: ALL",
                      u1RsvdPageLoc, 3);
        skb = dev_alloc_skb(totalpacketlen);
        memcpy((u8 *) skb_put(skb, totalpacketlen), &reserved_page_packet,
@@ -773,7 +773,7 @@ void rtl92d_set_fw_rsvdpagepkt(struct ieee80211_hw *hw, bool dl_finished)
                RT_TRACE(rtlpriv, COMP_POWER, DBG_LOUD,
                        ("Set RSVD page location to Fw.\n"));
                RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_DMESG,
-                             "H2C_RSVDPAGE:\n", u1RsvdPageLoc, 3);
+                             "H2C_RSVDPAGE", u1RsvdPageLoc, 3);
                rtl92d_fill_h2c_cmd(hw, H2C_RSVDPAGE,
                        sizeof(u1RsvdPageLoc), u1RsvdPageLoc);
        } else
index c8c4cf9240d3f37f59bbcbedfd2de5e148c152d0..5c8a639582add37fc68664fb0801f0d80ac25e53 100644 (file)
@@ -1777,7 +1777,7 @@ static void _rtl92de_read_adapter_info(struct ieee80211_hw *hw)
                RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG,
                         ("RTL819X Not boot from eeprom, check it !!"));
        }
-       RT_PRINT_DATA(rtlpriv, COMP_INIT, DBG_DMESG, ("MAP\n"),
+       RT_PRINT_DATA(rtlpriv, COMP_INIT, DBG_DMESG, "MAP",
                      hwinfo, HWSET_MAX_SIZE);
 
        eeprom_id = *((u16 *)&hwinfo[0]);
@@ -2279,7 +2279,7 @@ void rtl92de_set_key(struct ieee80211_hw *hw, u32 key_index,
                                 ("add one entry\n"));
                        if (is_pairwise) {
                                RT_PRINT_DATA(rtlpriv, COMP_SEC, DBG_LOUD,
-                                             "Pairwiase Key content :",
+                                             "Pairwise Key content",
                                              rtlpriv->sec.pairwise_key,
                                              rtlpriv->
                                              sec.key_len[PAIRWISE_KEYIDX]);
index 3637c0c3352513b2dab6a6c964feb61b0f2085ad..e84b8d5e4b1b84a45daebebb2177a90b5d98de40 100644 (file)
@@ -776,7 +776,7 @@ void rtl92de_tx_fill_cmddesc(struct ieee80211_hw *hw,
        }
 
        RT_PRINT_DATA(rtlpriv, COMP_CMD, DBG_LOUD,
-                     "H2C Tx Cmd Content\n", pdesc, TX_DESC_SIZE);
+                     "H2C Tx Cmd Content", pdesc, TX_DESC_SIZE);
        wmb();
        SET_TX_DESC_OWN(pdesc, 1);
 }
index c474486e391157d1d2be8c4ff40c4ca82db91ce1..f9ba077bc18f0d606b4cc521736280b438f573d8 100644 (file)
@@ -1636,7 +1636,7 @@ static void _rtl92se_read_adapter_info(struct ieee80211_hw *hw)
                        HWSET_MAX_SIZE_92S);
        }
 
-       RT_PRINT_DATA(rtlpriv, COMP_INIT, DBG_DMESG, ("MAP\n"),
+       RT_PRINT_DATA(rtlpriv, COMP_INIT, DBG_DMESG, "MAP",
                      hwinfo, HWSET_MAX_SIZE_92S);
 
        eeprom_id = *((u16 *)&hwinfo[0]);
@@ -2453,7 +2453,7 @@ void rtl92se_set_key(struct ieee80211_hw *hw, u32 key_index, u8 *p_macaddr,
                                 ("add one entry\n"));
                        if (is_pairwise) {
                                RT_PRINT_DATA(rtlpriv, COMP_SEC, DBG_LOUD,
-                                     "Pairwiase Key content :",
+                                     "Pairwise Key content",
                                       rtlpriv->sec.pairwise_key,
                                       rtlpriv->sec.key_len[PAIRWISE_KEYIDX]);