Skip to contentSkip to conversation

staging: rtl8192u: Remove print statements for error messages.

PATCH In review Payal Kshirsagar 2 participants 2 messages Apr 1, 2019 Staging

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 staging: rtl8192u: Remove print statements for error messages.

Challenge suggested by coccinelle.
Remove prints of error message, it is not needed to print error messages and remove unnecessary curly-braces.

---
Changes in v2:
-Remove unnecessary curly-braces.

 drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)
drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c +3 -6
index 1094454..b1ab8a4 100644
@@ -118,10 +118,8 @@ static struct sk_buff *ieee80211_ADDBA(struct ieee80211_device *ieee, u8 *Dst, s
 		return NULL;
 	}
 	skb = dev_alloc_skb(len + sizeof(struct rtl_80211_hdr_3addr)); //need to add something others? FIXME
-	if (!skb) {
-		IEEE80211_DEBUG(IEEE80211_DL_ERR, "can't alloc skb for ADDBA_REQ\n");
+	if (!skb)
 		return NULL;
-	}
 
 	memset(skb->data, 0, sizeof(struct rtl_80211_hdr_3addr));	//I wonder whether it's necessary. Apparently kernel will not do it when alloc a skb.
 	skb_reserve(skb, ieee->tx_headroom);
@@ -205,10 +203,9 @@ static struct sk_buff *ieee80211_DELBA(
 	DelbaParamSet.field.tid	= pBA->param_set.field.tid;
 
 	skb = dev_alloc_skb(len + sizeof(struct rtl_80211_hdr_3addr)); //need to add something others? FIXME
-	if (!skb) {
-		IEEE80211_DEBUG(IEEE80211_DL_ERR, "can't alloc skb for ADDBA_REQ\n");
+	if (!skb)
 		return NULL;
-	}
+
 //	memset(skb->data, 0, len+sizeof( struct rtl_80211_hdr_3addr));
 	skb_reserve(skb, ieee->tx_headroom);
 
Signature · 1 line
2.7.4
maintainer
#1 lore raw
Quoted 11 lines · Payal Kshirsagar

Challenge suggested by coccinelle.
Remove prints of error message, it is not needed to print error messages and remove unnecessary curly-braces.

---
Changes in v2:
-Remove unnecessary curly-braces.

 drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

This patch does not apply to my tree at all :(