Skip to contentSkip to conversation

staging: rtl8188eu: use __func__ in recv_linux.c

PATCH New Michael Straube 1 participant 3 messages Nov 10, 2018 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/3 staging: rtl8188eu: use __func__ in recv_linux.c

Use __func__ instead of hardcoded function name.
Reported by checkpatch.

---
 drivers/staging/rtl8188eu/os_dep/recv_linux.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/rtl8188eu/os_dep/recv_linux.c +2 -2
index 6f74f49bf3ab..764d33c4e839 100644
@@ -75,7 +75,7 @@ int rtw_recv_indicatepkt(struct adapter *padapter,
 	skb = precv_frame->pkt;
 	if (!skb) {
 		RT_TRACE(_module_recv_osdep_c_, _drv_err_,
-			 ("rtw_recv_indicatepkt():skb == NULL something wrong!!!!\n"));
+			 ("%s():skb == NULL something wrong!!!!\n", __func__));
 		goto _recv_indicatepkt_drop;
 	}
 
@@ -126,7 +126,7 @@ int rtw_recv_indicatepkt(struct adapter *padapter,
 	rtw_free_recvframe(precv_frame, pfree_recv_queue);
 
 	RT_TRACE(_module_recv_osdep_c_, _drv_info_,
-		 ("\n rtw_recv_indicatepkt :after netif_rx!!!!\n"));
+		 ("\n %s :after netif_rx!!!!\n", __func__));
 
 	return _SUCCESS;
 
Signature · 1 line
2.19.1
#1 lore raw

PATCH 2/3 staging: rtl8188eu: add spaces around '*' in recv_linux.c

Add spaces around '*' to conform with kernel coding style. Reported by checkpatch.

---
 drivers/staging/rtl8188eu/os_dep/recv_linux.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/rtl8188eu/os_dep/recv_linux.c +1 -1
index 764d33c4e839..0d253a84904d 100644
@@ -38,7 +38,7 @@ void rtw_handle_tkip_mic_err(struct adapter *padapter, u8 bgroup)
 	} else {
 		cur_time = jiffies;
 
-		if (cur_time - psecuritypriv->last_mic_err_time < 60*HZ) {
+		if (cur_time - psecuritypriv->last_mic_err_time < 60 * HZ) {
 			psecuritypriv->btkip_countermeasure = true;
 			psecuritypriv->last_mic_err_time = 0;
 			psecuritypriv->btkip_countermeasure_time = cur_time;
Signature · 1 line
2.19.1
#2 lore raw

PATCH 3/3 staging: rtl8188eu: remove unnecessary parentheses in recv_linux.c

In reply to Michael Straube

Remove unnecessary parentheses reported by checkpatch.

---
 drivers/staging/rtl8188eu/os_dep/recv_linux.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/rtl8188eu/os_dep/recv_linux.c +2 -2
index 0d253a84904d..9c9339863a4a 100644
@@ -69,8 +69,8 @@ int rtw_recv_indicatepkt(struct adapter *padapter,
 	struct sk_buff *skb;
 	struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
 
-	precvpriv = &(padapter->recvpriv);
-	pfree_recv_queue = &(precvpriv->free_recv_queue);
+	precvpriv = &padapter->recvpriv;
+	pfree_recv_queue = &precvpriv->free_recv_queue;
 
 	skb = precv_frame->pkt;
 	if (!skb) {
Signature · 1 line
2.19.1