From: Hariprasad Kelam <hariprasad.kelam@gmail.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Hariprasad Kelam <hariprasad.kelam@gmail.com>,
Jeeeun Evans <jeeeunevans@gmail.com>,
Larry Finger <Larry.Finger@lwfinger.net>,
Quytelda Kahja <quytelda@tamalin.org>,
Omer Efrat <omer.efrat@tandemg.com>,
Arnd Bergmann <arnd@arndb.de>,
Puranjay Mohan <puranjay12@gmail.com>,
devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: [PATCH] staging: rtl8723bs: os_dep: Make use rtw_zmalloc
Date: Sun, 16 Jun 2019 10:46:19 +0530 [thread overview]
Message-ID: <20190616051619.GA15036@hari-Inspiron-1545> (raw)
rtw_malloc with memset can be replaced with rtw_zmalloc.
Signed-off-by: Hariprasad Kelam <hariprasad.kelam@gmail.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
next reply other threads:[~2019-06-16 5:19 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-16 5:16 Hariprasad Kelam [this message]
2019-06-18 6:59 ` [PATCH] staging: rtl8723bs: os_dep: Make use rtw_zmalloc Greg Kroah-Hartman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190616051619.GA15036@hari-Inspiron-1545 \
--to=hariprasad.kelam@gmail.com \
--cc=Larry.Finger@lwfinger.net \
--cc=arnd@arndb.de \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=jeeeunevans@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=omer.efrat@tandemg.com \
--cc=puranjay12@gmail.com \
--cc=quytelda@tamalin.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).