lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAHb8M2DKZP9+Xs-OP_MnaTCKgmNPXAxrYs3GwO55NcsHdyTWzA@mail.gmail.com>
Date:	Fri, 21 Mar 2014 13:36:31 +0900
From:	DaeSeok Youn <daeseok.youn@...il.com>
To:	Greg KH <gregkh@...uxfoundation.org>
Cc:	nandini h <nandu.hgowda@...il.com>,
	devel <devel@...verdev.osuosl.org>,
	Shaun Laing <shaun@...source.ca>,
	Gülşah Köse <gulsah.1004@...il.com>,
	"sachin.kamat" <sachin.kamat@...aro.org>,
	peter.p.waskiewicz.jr@...el.com,
	Ebru Akagunduz <ebru.akagunduz@...il.com>,
	Dulshani Gunawardhana <dulshani.gunawardhana89@...il.com>,
	linux-kernel <linux-kernel@...r.kernel.org>,
	David Howells <dhowells@...hat.com>,
	Himangi Saraogi <himangi774@...il.com>,
	viro <viro@...iv.linux.org.uk>, Joe Perches <joe@...ches.com>,
	Chekameh Cobbler <fempsci@...il.com>,
	Trac Notifications <speiro@....upv.es>
Subject: Re: [PATCH v2] staging: cxt1e1: replace OS_kmalloc/OS_kfree with kmalloc/kfree

2014-03-21 13:27 GMT+09:00 Greg KH <gregkh@...uxfoundation.org>:
> On Fri, Mar 21, 2014 at 01:15:23PM +0900, Daeseok Youn wrote:
>>
>> Replace OS_kmalloc/OS_kfree with kmalloc/kfree.
>
> You should replace it with kzalloc, not kmalloc, as OS_kmalloc() zeroed
> out the allocated data:

I think some case does not need to get zeroed memory. :-)
I will change that and send it again.

Thanks for review.
Daeseok Youn.

>
>
>> -static inline void *
>> -OS_kmalloc (size_t size)
>> -{
>> -    char       *ptr = kmalloc (size, GFP_KERNEL | GFP_DMA);
>> -
>> -    if (ptr)
>> -        memset (ptr, 0, size);
>> -    return ptr;
>> -}
>
> greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ