[3.19.y-ckt stable] Patch "[stable-only] crypto: {blk, giv}cipher: Set has_setkey" has been added to the 3.19.y-ckt tree
Kamal Mostafa
kamal at canonical.com
Thu Mar 24 22:35:17 UTC 2016
This is a note to let you know that I have just added a patch titled
[stable-only] crypto: {blk,giv}cipher: Set has_setkey
to the linux-3.19.y-queue branch of the 3.19.y-ckt extended stable tree
which can be found at:
http://kernel.ubuntu.com/git/ubuntu/linux.git/log/?h=linux-3.19.y-queue
This patch is scheduled to be released in version 3.19.8-ckt18.
If you, or anyone else, feels it should not be added to this tree, please
reply to this email.
For more information about the 3.19.y-ckt tree, see
https://wiki.ubuntu.com/Kernel/Dev/ExtendedStable
Thanks.
-Kamal
---8<------------------------------------------------------------
>From 5473bbd9ca2af0f4480bec6d4071a9d189bf90d1 Mon Sep 17 00:00:00 2001
From: Ben Hutchings <ben at decadent.org.uk>
Date: Mon, 7 Mar 2016 03:40:02 +0000
Subject: [stable-only] crypto: {blk,giv}cipher: Set has_setkey
Commit a1383cd86a06 ("crypto: skcipher - Add crypto_skcipher_has_setkey")
was incorrectly backported to the 3.2.y and 3.16.y stable branches.
We need to set ablkcipher_tfm::has_setkey in the
crypto_init_blkcipher_ops_async() and crypto_init_givcipher_ops()
functions as well as crypto_init_ablkcipher_ops().
Signed-off-by: Ben Hutchings <ben at decadent.org.uk>
Signed-off-by: Kamal Mostafa <kamal at canonical.com>
---
crypto/ablkcipher.c | 1 +
crypto/blkcipher.c | 1 +
2 files changed, 2 insertions(+)
diff --git a/crypto/ablkcipher.c b/crypto/ablkcipher.c
index 5da1652..970b48e 100644
--- a/crypto/ablkcipher.c
+++ b/crypto/ablkcipher.c
@@ -457,6 +457,7 @@ static int crypto_init_givcipher_ops(struct crypto_tfm *tfm, u32 type,
crt->givdecrypt = alg->givdecrypt ?: no_givdecrypt;
crt->base = __crypto_ablkcipher_cast(tfm);
crt->ivsize = alg->ivsize;
+ crt->has_setkey = alg->max_keysize;
return 0;
}
diff --git a/crypto/blkcipher.c b/crypto/blkcipher.c
index 7180cb2..3c551d4 100644
--- a/crypto/blkcipher.c
+++ b/crypto/blkcipher.c
@@ -471,6 +471,7 @@ static int crypto_init_blkcipher_ops_async(struct crypto_tfm *tfm)
}
crt->base = __crypto_ablkcipher_cast(tfm);
crt->ivsize = alg->ivsize;
+ crt->has_setkey = alg->max_keysize;
return 0;
}
--
2.7.0
More information about the kernel-team
mailing list