Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a234bdc9 authored by Pekka Enberg's avatar Pekka Enberg
Browse files

slab: document kzfree() zeroing behavior



As suggested by Alan Cox, document the fact that kzfree() can zero out a great
deal more memory than the what the user requested from kmalloc().

Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: default avatarPekka Enberg <penberg@cs.helsinki.fi>
parent 59a3759d
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -166,6 +166,10 @@ EXPORT_SYMBOL(krealloc);
 *
 * The memory of the object @p points to is zeroed before freed.
 * If @p is %NULL, kzfree() does nothing.
 *
 * Note: this function zeroes the whole allocated buffer which can be a good
 * deal bigger than the requested buffer size passed to kmalloc(). So be
 * careful when using this function in performance sensitive code.
 */
void kzfree(const void *p)
{