From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932622AbcC2UYO (ORCPT ); Tue, 29 Mar 2016 16:24:14 -0400 Received: from shadbolt.e.decadent.org.uk ([88.96.1.126]:45091 "EHLO shadbolt.e.decadent.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754256AbcC2UEz (ORCPT ); Tue, 29 Mar 2016 16:04:55 -0400 Content-Type: text/plain; charset="UTF-8" Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 From: Ben Hutchings To: linux-kernel@vger.kernel.org, stable@vger.kernel.org CC: akpm@linux-foundation.org Date: Tue, 29 Mar 2016 20:18:22 +0100 Message-ID: X-Mailer: LinuxStableQueue (scripts by bwh) Subject: [PATCH 3.2 02/62] crypto: {blk,giv}cipher: Set has_setkey In-Reply-To: X-SA-Exim-Connect-IP: 213.146.164.225 X-SA-Exim-Mail-From: ben@decadent.org.uk X-SA-Exim-Scanned: No (on shadbolt.decadent.org.uk); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 3.2.79-rc1 review patch. If anyone has any objections, please let me know. ------------------ From: Ben Hutchings 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 --- --- a/crypto/ablkcipher.c +++ b/crypto/ablkcipher.c @@ -461,6 +461,7 @@ static int crypto_init_givcipher_ops(str crt->givdecrypt = alg->givdecrypt ?: no_givdecrypt; crt->base = __crypto_ablkcipher_cast(tfm); crt->ivsize = alg->ivsize; + crt->has_setkey = alg->max_keysize; return 0; } --- a/crypto/blkcipher.c +++ b/crypto/blkcipher.c @@ -458,6 +458,7 @@ static int crypto_init_blkcipher_ops_asy } crt->base = __crypto_ablkcipher_cast(tfm); crt->ivsize = alg->ivsize; + crt->has_setkey = alg->max_keysize; return 0; }