Commit 98611b00 authored by Larry Finger's avatar Larry Finger Committed by Kalle Valo

rtlwifi: rtl8821ae: Rename RT_TRACE to rtl_dbg

Change the misleading macro name to one that is more descriptive for
rtl8821ae. 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/20200831184536.29950-1-Larry.Finger@lwfinger.net
parent 2c92790b
...@@ -20,8 +20,8 @@ void rtl8821ae_sw_led_on(struct ieee80211_hw *hw, struct rtl_led *pled) ...@@ -20,8 +20,8 @@ void rtl8821ae_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:
...@@ -37,8 +37,8 @@ void rtl8821ae_sw_led_on(struct ieee80211_hw *hw, struct rtl_led *pled) ...@@ -37,8 +37,8 @@ void rtl8821ae_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_LOUD, rtl_dbg(rtlpriv, COMP_ERR, DBG_LOUD,
"switch case %#x not processed\n", pled->ledpin); "switch case %#x not processed\n", pled->ledpin);
break; break;
} }
pled->ledon = true; pled->ledon = true;
...@@ -64,9 +64,9 @@ void rtl8812ae_sw_led_on(struct ieee80211_hw *hw, struct rtl_led *pled) ...@@ -64,9 +64,9 @@ void rtl8812ae_sw_led_on(struct ieee80211_hw *hw, struct rtl_led *pled)
break; break;
} }
RT_TRACE(rtlpriv, COMP_LED, DBG_LOUD, rtl_dbg(rtlpriv, COMP_LED, DBG_LOUD,
"In SwLedOn, LedAddr:%X LEDPIN=%d\n", "In SwLedOn, LedAddr:%X LEDPIN=%d\n",
ledreg, pled->ledpin); ledreg, pled->ledpin);
ledcfg = rtl_read_byte(rtlpriv, ledreg); ledcfg = rtl_read_byte(rtlpriv, ledreg);
ledcfg |= BIT(5); /*Set 0x4c[21]*/ ledcfg |= BIT(5); /*Set 0x4c[21]*/
...@@ -81,8 +81,8 @@ void rtl8821ae_sw_led_off(struct ieee80211_hw *hw, struct rtl_led *pled) ...@@ -81,8 +81,8 @@ void rtl8821ae_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);
...@@ -109,8 +109,8 @@ void rtl8821ae_sw_led_off(struct ieee80211_hw *hw, struct rtl_led *pled) ...@@ -109,8 +109,8 @@ void rtl8821ae_sw_led_off(struct ieee80211_hw *hw, struct rtl_led *pled)
rtl_write_byte(rtlpriv, REG_LEDCFG1, ledcfg|BIT(3)); rtl_write_byte(rtlpriv, REG_LEDCFG1, ledcfg|BIT(3));
break; break;
default: default:
RT_TRACE(rtlpriv, COMP_ERR, DBG_LOUD, rtl_dbg(rtlpriv, COMP_ERR, DBG_LOUD,
"switch case %#x not processed\n", pled->ledpin); "switch case %#x not processed\n", pled->ledpin);
break; break;
} }
pled->ledon = false; pled->ledon = false;
...@@ -135,9 +135,9 @@ void rtl8812ae_sw_led_off(struct ieee80211_hw *hw, struct rtl_led *pled) ...@@ -135,9 +135,9 @@ void rtl8812ae_sw_led_off(struct ieee80211_hw *hw, struct rtl_led *pled)
break; break;
} }
RT_TRACE(rtlpriv, COMP_LED, DBG_LOUD, rtl_dbg(rtlpriv, COMP_LED, DBG_LOUD,
"In SwLedOff,LedAddr:%X LEDPIN=%d\n", "In SwLedOff,LedAddr:%X LEDPIN=%d\n",
ledreg, pled->ledpin); ledreg, pled->ledpin);
/*Open-drain arrangement for controlling the LED*/ /*Open-drain arrangement for controlling the LED*/
if (rtlpriv->ledctl.led_opendrain) { if (rtlpriv->ledctl.led_opendrain) {
u8 ledcfg = rtl_read_byte(rtlpriv, ledreg); u8 ledcfg = rtl_read_byte(rtlpriv, ledreg);
...@@ -207,7 +207,7 @@ void rtl8821ae_led_control(struct ieee80211_hw *hw, ...@@ -207,7 +207,7 @@ void rtl8821ae_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", rtl_dbg(rtlpriv, COMP_LED, DBG_LOUD, "ledaction %d,\n",
ledaction); ledaction);
_rtl8821ae_sw_led_control(hw, ledaction); _rtl8821ae_sw_led_control(hw, ledaction);
} }
...@@ -428,13 +428,13 @@ static bool _rtl8821ae_phy_rf6052_config_parafile(struct ieee80211_hw *hw) ...@@ -428,13 +428,13 @@ static bool _rtl8821ae_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;
} }
} }
/*put arrays in dm.c*/ /*put arrays in dm.c*/
RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, "\n"); rtl_dbg(rtlpriv, COMP_INIT, DBG_TRACE, "\n");
return rtstatus; return rtstatus;
} }
...@@ -391,7 +391,7 @@ static bool rtl8821ae_get_rxdesc_is_ht(struct ieee80211_hw *hw, __le32 *pdesc) ...@@ -391,7 +391,7 @@ static bool rtl8821ae_get_rxdesc_is_ht(struct ieee80211_hw *hw, __le32 *pdesc)
rx_rate = get_rx_desc_rxmcs(pdesc); rx_rate = get_rx_desc_rxmcs(pdesc);
RT_TRACE(rtlpriv, COMP_RXDESC, DBG_LOUD, "rx_rate=0x%02x.\n", rx_rate); rtl_dbg(rtlpriv, COMP_RXDESC, DBG_LOUD, "rx_rate=0x%02x.\n", rx_rate);
if ((rx_rate >= DESC_RATEMCS0) && (rx_rate <= DESC_RATEMCS15)) if ((rx_rate >= DESC_RATEMCS0) && (rx_rate <= DESC_RATEMCS15))
return true; return true;
...@@ -405,7 +405,7 @@ static bool rtl8821ae_get_rxdesc_is_vht(struct ieee80211_hw *hw, __le32 *pdesc) ...@@ -405,7 +405,7 @@ static bool rtl8821ae_get_rxdesc_is_vht(struct ieee80211_hw *hw, __le32 *pdesc)
rx_rate = get_rx_desc_rxmcs(pdesc); rx_rate = get_rx_desc_rxmcs(pdesc);
RT_TRACE(rtlpriv, COMP_RXDESC, DBG_LOUD, "rx_rate=0x%02x.\n", rx_rate); rtl_dbg(rtlpriv, COMP_RXDESC, DBG_LOUD, "rx_rate=0x%02x.\n", rx_rate);
if (rx_rate >= DESC_RATEVHT1SS_MCS0) if (rx_rate >= DESC_RATEVHT1SS_MCS0)
return true; return true;
...@@ -461,12 +461,12 @@ bool rtl8821ae_rx_query_desc(struct ieee80211_hw *hw, ...@@ -461,12 +461,12 @@ bool rtl8821ae_rx_query_desc(struct ieee80211_hw *hw,
status->vht_nss = rtl8821ae_get_rx_vht_nss(hw, pdesc); status->vht_nss = rtl8821ae_get_rx_vht_nss(hw, pdesc);
status->is_cck = RTL8821AE_RX_HAL_IS_CCK_RATE(status->rate); status->is_cck = RTL8821AE_RX_HAL_IS_CCK_RATE(status->rate);
RT_TRACE(rtlpriv, COMP_RXDESC, DBG_LOUD, rtl_dbg(rtlpriv, COMP_RXDESC, DBG_LOUD,
"rx_packet_bw=%s,is_ht %d, is_vht %d, vht_nss=%d,is_short_gi %d.\n", "rx_packet_bw=%s,is_ht %d, is_vht %d, vht_nss=%d,is_short_gi %d.\n",
(status->rx_packet_bw == 2) ? "80M" : (status->rx_packet_bw == 2) ? "80M" :
(status->rx_packet_bw == 1) ? "40M" : "20M", (status->rx_packet_bw == 1) ? "40M" : "20M",
status->is_ht, status->is_vht, status->vht_nss, status->is_ht, status->is_vht, status->vht_nss,
status->is_short_gi); status->is_short_gi);
if (get_rx_status_desc_rpt_sel(pdesc)) if (get_rx_status_desc_rpt_sel(pdesc))
status->packet_report_type = C2H_PACKET; status->packet_report_type = C2H_PACKET;
...@@ -483,9 +483,9 @@ bool rtl8821ae_rx_query_desc(struct ieee80211_hw *hw, ...@@ -483,9 +483,9 @@ bool rtl8821ae_rx_query_desc(struct ieee80211_hw *hw,
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;
...@@ -558,9 +558,10 @@ static u8 rtl8821ae_bw_mapping(struct ieee80211_hw *hw, ...@@ -558,9 +558,10 @@ static u8 rtl8821ae_bw_mapping(struct ieee80211_hw *hw,
struct rtl_phy *rtlphy = &rtlpriv->phy; struct rtl_phy *rtlphy = &rtlpriv->phy;
u8 bw_setting_of_desc = 0; u8 bw_setting_of_desc = 0;
RT_TRACE(rtlpriv, COMP_SEND, DBG_TRACE, rtl_dbg(rtlpriv, COMP_SEND, DBG_TRACE,
"rtl8821ae_bw_mapping, current_chan_bw %d, packet_bw %d\n", "%s, current_chan_bw %d, packet_bw %d\n",
rtlphy->current_chan_bw, ptcb_desc->packet_bw); __func__,
rtlphy->current_chan_bw, ptcb_desc->packet_bw);
if (rtlphy->current_chan_bw == HT_CHANNEL_WIDTH_80) { if (rtlphy->current_chan_bw == HT_CHANNEL_WIDTH_80) {
if (ptcb_desc->packet_bw == HT_CHANNEL_WIDTH_80) if (ptcb_desc->packet_bw == HT_CHANNEL_WIDTH_80)
...@@ -602,8 +603,9 @@ static u8 rtl8821ae_sc_mapping(struct ieee80211_hw *hw, ...@@ -602,8 +603,9 @@ static u8 rtl8821ae_sc_mapping(struct ieee80211_hw *hw,
sc_setting_of_desc = sc_setting_of_desc =
VHT_DATA_SC_40_UPPER_OF_80MHZ; VHT_DATA_SC_40_UPPER_OF_80MHZ;
else else
RT_TRACE(rtlpriv, COMP_SEND, DBG_LOUD, rtl_dbg(rtlpriv, COMP_SEND, DBG_LOUD,
"rtl8821ae_sc_mapping: Not Correct Primary40MHz Setting\n"); "%s: Not Correct Primary40MHz Setting\n",
__func__);
} else { } else {
if ((mac->cur_40_prime_sc == if ((mac->cur_40_prime_sc ==
HAL_PRIME_CHNL_OFFSET_LOWER) && HAL_PRIME_CHNL_OFFSET_LOWER) &&
...@@ -630,8 +632,9 @@ static u8 rtl8821ae_sc_mapping(struct ieee80211_hw *hw, ...@@ -630,8 +632,9 @@ static u8 rtl8821ae_sc_mapping(struct ieee80211_hw *hw,
sc_setting_of_desc = sc_setting_of_desc =
VHT_DATA_SC_20_UPPERST_OF_80MHZ; VHT_DATA_SC_20_UPPERST_OF_80MHZ;
else else
RT_TRACE(rtlpriv, COMP_SEND, DBG_LOUD, rtl_dbg(rtlpriv, COMP_SEND, DBG_LOUD,
"rtl8821ae_sc_mapping: Not Correct Primary40MHz Setting\n"); "%s: Not Correct Primary40MHz Setting\n",
__func__);
} }
} else if (rtlphy->current_chan_bw == HT_CHANNEL_WIDTH_20_40) { } else if (rtlphy->current_chan_bw == HT_CHANNEL_WIDTH_20_40) {
if (ptcb_desc->packet_bw == HT_CHANNEL_WIDTH_20_40) { if (ptcb_desc->packet_bw == HT_CHANNEL_WIDTH_20_40) {
...@@ -693,8 +696,8 @@ void rtl8821ae_tx_fill_desc(struct ieee80211_hw *hw, ...@@ -693,8 +696,8 @@ void rtl8821ae_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, rtl_dbg(rtlpriv, COMP_SEND, DBG_TRACE,
"DMA mapping error\n"); "DMA mapping error\n");
return; return;
} }
clear_pci_tx_desc_content(pdesc, sizeof(struct tx_desc_8821ae)); clear_pci_tx_desc_content(pdesc, sizeof(struct tx_desc_8821ae));
...@@ -708,9 +711,9 @@ void rtl8821ae_tx_fill_desc(struct ieee80211_hw *hw, ...@@ -708,9 +711,9 @@ void rtl8821ae_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);
rtl8821ae_insert_emcontent(ptcb_desc, rtl8821ae_insert_emcontent(ptcb_desc,
(__le32 *)skb->data); (__le32 *)skb->data);
} }
...@@ -789,8 +792,8 @@ void rtl8821ae_tx_fill_desc(struct ieee80211_hw *hw, ...@@ -789,8 +792,8 @@ void rtl8821ae_tx_fill_desc(struct ieee80211_hw *hw,
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);
} }
...@@ -822,7 +825,7 @@ void rtl8821ae_tx_fill_desc(struct ieee80211_hw *hw, ...@@ -822,7 +825,7 @@ void rtl8821ae_tx_fill_desc(struct ieee80211_hw *hw,
} }
rtl8821ae_dm_set_tx_ant_by_tx_info(hw, pdesc8, ptcb_desc->mac_id); rtl8821ae_dm_set_tx_ant_by_tx_info(hw, pdesc8, ptcb_desc->mac_id);
RT_TRACE(rtlpriv, COMP_SEND, DBG_TRACE, "\n"); rtl_dbg(rtlpriv, COMP_SEND, DBG_TRACE, "\n");
} }
void rtl8821ae_tx_fill_cmddesc(struct ieee80211_hw *hw, void rtl8821ae_tx_fill_cmddesc(struct ieee80211_hw *hw,
...@@ -839,8 +842,8 @@ void rtl8821ae_tx_fill_cmddesc(struct ieee80211_hw *hw, ...@@ -839,8 +842,8 @@ void rtl8821ae_tx_fill_cmddesc(struct ieee80211_hw *hw,
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