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) ...@@ -201,8 +201,7 @@ static int __init prng_init(void)
static void __exit prng_exit(void) static void __exit prng_exit(void)
{ {
/* wipe me */ /* wipe me */
memset(p->buf, 0, prng_chunk_size); kzfree(p->buf);
kfree(p->buf);
kfree(p); kfree(p);
misc_deregister(&prng_dev); misc_deregister(&prng_dev);
......
...@@ -781,8 +781,7 @@ static long zcrypt_pcixcc_send_cprb(struct zcrypt_device *zdev, ...@@ -781,8 +781,7 @@ static long zcrypt_pcixcc_send_cprb(struct zcrypt_device *zdev,
/* Signal pending. */ /* Signal pending. */
ap_cancel_message(zdev->ap_dev, &ap_msg); ap_cancel_message(zdev->ap_dev, &ap_msg);
out_free: out_free:
memset(ap_msg.message, 0x0, ap_msg.length); kzfree(ap_msg.message);
kfree(ap_msg.message);
return rc; 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