[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190616051619.GA15036@hari-Inspiron-1545>
Date: Sun, 16 Jun 2019 10:46:19 +0530
From: Hariprasad Kelam <hariprasad.kelam@...il.com>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Hariprasad Kelam <hariprasad.kelam@...il.com>,
Jeeeun Evans <jeeeunevans@...il.com>,
Larry Finger <Larry.Finger@...inger.net>,
Quytelda Kahja <quytelda@...alin.org>,
Omer Efrat <omer.efrat@...demg.com>,
Arnd Bergmann <arnd@...db.de>,
Puranjay Mohan <puranjay12@...il.com>,
devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org
Subject: [PATCH] staging: rtl8723bs: os_dep: Make use rtw_zmalloc
rtw_malloc with memset can be replaced with rtw_zmalloc.
Signed-off-by: Hariprasad Kelam <hariprasad.kelam@...il.com>
---
drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c
index 9bc6856..aa7cc50 100644
--- a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c
+++ b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c
@@ -1078,12 +1078,10 @@ static int cfg80211_rtw_add_key(struct wiphy *wiphy, struct net_device *ndev,
DBG_871X("pairwise =%d\n", pairwise);
param_len = sizeof(struct ieee_param) + params->key_len;
- param = rtw_malloc(param_len);
+ param = rtw_zmalloc(param_len);
if (param == NULL)
return -1;
- memset(param, 0, param_len);
-
param->cmd = IEEE_CMD_SET_ENCRYPTION;
memset(param->sta_addr, 0xff, ETH_ALEN);
--
2.7.4
Powered by blists - more mailing lists