* [PATCH] Staging: rtl8192e: rtllib_softmac: Do not print message if kzalloc() failed.
@ 2016-03-03 11:30 Sandhya Bankar
0 siblings, 0 replies; only message in thread
From: Sandhya Bankar @ 2016-03-03 11:30 UTC (permalink / raw)
To: outreachy-kernel
As kzalloc() has its own messges, so no need of error messsge after kzalloc() failed . Also removing the NULL test whose purpose is to print the error message only and not returning any error.
Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com>
---
drivers/staging/rtl8192e/rtllib_softmac.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/staging/rtl8192e/rtllib_softmac.c b/drivers/staging/rtl8192e/rtllib_softmac.c
index 25b5b5e..0c891c8 100644
--- a/drivers/staging/rtl8192e/rtllib_softmac.c
+++ b/drivers/staging/rtl8192e/rtllib_softmac.c
@@ -2980,8 +2980,6 @@ void rtllib_softmac_init(struct rtllib_device *ieee)
for (i = 0; i < 5; i++)
ieee->seq_ctrl[i] = 0;
ieee->pDot11dInfo = kzalloc(sizeof(struct rt_dot11d_info), GFP_ATOMIC);
- if (!ieee->pDot11dInfo)
- netdev_err(ieee->dev, "Can't alloc memory for DOT11D\n");
ieee->LinkDetectInfo.SlotIndex = 0;
ieee->LinkDetectInfo.SlotNum = 2;
ieee->LinkDetectInfo.NumRecvBcnInPeriod = 0;
--
1.8.3.4
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2016-03-03 19:31 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-03 11:30 [PATCH] Staging: rtl8192e: rtllib_softmac: Do not print message if kzalloc() failed Sandhya Bankar
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.