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] [thread-next>] [day] [month] [year] [list]
Message-ID: <20120214072017.GF26353@mwanda>
Date:	Tue, 14 Feb 2012 10:20:17 +0300
From:	Dan Carpenter <dan.carpenter@...cle.com>
To:	Christoph Lameter <cl@...ux.com>
Cc:	Xi Wang <xi.wang@...il.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Jesper Juhl <jj@...osbits.net>, Jens Axboe <axboe@...nel.dk>,
	Pekka Enberg <penberg@...nel.org>,
	linux-kernel@...r.kernel.org, Matt Mackall <mpm@...enic.com>,
	David Rientjes <rientjes@...gle.com>
Subject: Re: [PATCH RFC v2] slab: introduce kmalloc_array

SAFE_ARRAY_SIZE() would return the size if there were no overflow
and -1 on errors?  We can't return zero on errors because there are
a lot of places which do zero size allocations and it's valid.  It
seems ugly.

I really think that's over thinking things.  Let's just match
kcalloc() exactly except without zeroing.  The BUILD_BUG_ON() thing
is an over complication as well.  We haven't needed it for
kcalloc().

The only impossible bit is picking the right name.

regards,
dan carpenter


Download attachment "signature.asc" of type "application/pgp-signature" (837 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ