diff options
Diffstat (limited to 'drivers/s390/crypto')
-rw-r--r-- | drivers/s390/crypto/zcrypt_api.c | 6 | ||||
-rw-r--r-- | drivers/s390/crypto/zcrypt_pcixcc.c | 3 |
2 files changed, 3 insertions, 6 deletions
diff --git a/drivers/s390/crypto/zcrypt_api.c b/drivers/s390/crypto/zcrypt_api.c index cb22b97944b..65b6a96afe6 100644 --- a/drivers/s390/crypto/zcrypt_api.c +++ b/drivers/s390/crypto/zcrypt_api.c @@ -128,8 +128,7 @@ static void __zcrypt_increase_preference(struct zcrypt_device *zdev) if (l == zdev->list.prev) return; /* Move zdev behind l */ - list_del(&zdev->list); - list_add(&zdev->list, l); + list_move(&zdev->list, l); } /** @@ -157,8 +156,7 @@ static void __zcrypt_decrease_preference(struct zcrypt_device *zdev) if (l == zdev->list.next) return; /* Move zdev before l */ - list_del(&zdev->list); - list_add_tail(&zdev->list, l); + list_move_tail(&zdev->list, l); } static void zcrypt_device_release(struct kref *kref) diff --git a/drivers/s390/crypto/zcrypt_pcixcc.c b/drivers/s390/crypto/zcrypt_pcixcc.c index e7a1e22e77a..c20d4790258 100644 --- a/drivers/s390/crypto/zcrypt_pcixcc.c +++ b/drivers/s390/crypto/zcrypt_pcixcc.c @@ -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; } |