mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hariprasad Kelam <hariprasad.kelam@gmail.com>
To: Dan Carpenter <dan.carpenter@oracle.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Michael Straube <straube.linux@gmail.com>,
	Nishka Dasgupta <nishkadg.linux@gmail.com>,
	Mamta Shukla <mamtashukla555@gmail.com>,
	Emanuel Bennici <benniciemanuel78@gmail.com>,
	Shobhit Kukreti <shobhitkukreti@gmail.com>,
	Puranjay Mohan <puranjay12@gmail.com>,
	devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] staging: rtl8723bs: os_dep: ioctl_linux:  Make use rtw_zmalloc
Date: Tue, 18 Jun 2019 06:58:20 +0530	[thread overview]
Message-ID: <20190618012819.GA7963@hari-Inspiron-1545> (raw)
In-Reply-To: <20190616071522.GE28859@kadam>

On Sun, Jun 16, 2019 at 10:15:22AM +0300, Dan Carpenter wrote:
> On Sun, Jun 16, 2019 at 11:02:50AM +0530, Hariprasad Kelam wrote:
> > rtw_malloc with memset can be replace with rtw_zmalloc.
> > 
> > Signed-off-by: Hariprasad Kelam <hariprasad.kelam@gmail.com>
> > ---
> >  drivers/staging/rtl8723bs/os_dep/ioctl_linux.c | 12 +++---------
> >  1 file changed, 3 insertions(+), 9 deletions(-)
> > 
> > diff --git a/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c b/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c
> > index fc3885d..c59e366 100644
> > --- a/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c
> > +++ b/drivers/staging/rtl8723bs/os_dep/ioctl_linux.c
> > @@ -478,14 +478,12 @@ static int wpa_set_encryption(struct net_device *dev, struct ieee_param *param,
> >  		if (wep_key_len > 0) {
> >  			wep_key_len = wep_key_len <= 5 ? 5 : 13;
> >  			wep_total_len = wep_key_len + FIELD_OFFSET(struct ndis_802_11_wep, KeyMaterial);
> > -			pwep = rtw_malloc(wep_total_len);
> > +			pwep = rtw_zmalloc(wep_total_len);
> 
> We should not introduce new uses of rtw_malloc() or rtw_zmalloc().  They
> are buggy garbage.  Use normall kmalloc() and kzalloc().
Hi Dan Carpenter,

Sure , will  resend this patch with suggested changes.

Thanks,
Hariprasad k

> 
> regards,
> dan carpenter
 

      reply	other threads:[~2019-06-18  1:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-16  5:32 Hariprasad Kelam
2019-06-16  7:15 ` Dan Carpenter
2019-06-18  1:28   ` Hariprasad Kelam [this message]

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=20190618012819.GA7963@hari-Inspiron-1545 \
    --to=hariprasad.kelam@gmail.com \
    --cc=benniciemanuel78@gmail.com \
    --cc=dan.carpenter@oracle.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mamtashukla555@gmail.com \
    --cc=nishkadg.linux@gmail.com \
    --cc=puranjay12@gmail.com \
    --cc=shobhitkukreti@gmail.com \
    --cc=straube.linux@gmail.com \
    /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

all inboxes | Powered by JetHome®