Skip to contentSkip to conversation

staging: wilc1000: Fix "Possible unnecessary 'out of memory' message" checkpatch.pl warning

PATCH New Anchal Jain 1 participant 1 message Feb 15, 2016 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: wilc1000: Fix "Possible unnecessary 'out of memory' message" checkpatch.pl warning

Fix "Possible unnecessary 'out of memory' message" checkpatch.pl warning

---
 drivers/staging/wilc1000/wilc_wlan.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/staging/wilc1000/wilc_wlan.c +1 -3
index 397ad45..ba2b940 100644
@@ -355,10 +355,8 @@ static int wilc_wlan_txq_add_cfg_pkt(struct wilc_vif *vif, u8 *buffer,
 	}
 
 	tqe = kmalloc(sizeof(*tqe), GFP_ATOMIC);
-	if (!tqe) {
-		netdev_err(vif->ndev, "Failed to allocate memory\n");
+	if (!tqe)
 		return 0;
-	}
 
 	tqe->type = WILC_CFG_PKT;
 	tqe->buffer = buffer;
Signature · 1 line
1.9.1