Commit 3e75a902 authored by Johannes Weiner's avatar Johannes Weiner Committed by Martin Schwidefsky

[S390] use kzfree()

Use kzfree() instead of memset() + kfree().
Signed-off-by: default avatarJohannes Weiner <hannes@cmpxchg.org>
Reviewed-by: default avatarPekka Enberg <penberg@cs.helsinki.fi>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: default avatarMartin Schwidefsky <schwidefsky@de.ibm.com>
parent 6aa0d3a9
......@@ -201,8 +201,7 @@ static int __init prng_init(void)
static void __exit prng_exit(void)
{
/* wipe me */
memset(p->buf, 0, prng_chunk_size);
kfree(p->buf);
kzfree(p->buf);
kfree(p);
misc_deregister(&prng_dev);
......
......@@ -781,8 +781,7 @@ static long zcrypt_pcixcc_send_cprb(struct zcrypt_device *zdev,
/* Signal pending. */
ap_cancel_message(zdev->ap_dev, &ap_msg);
out_free:
memset(ap_msg.message, 0x0, ap_msg.length);
kfree(ap_msg.message);
kzfree(ap_msg.message);
return rc;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment