From patchwork Thu Apr 28 14:15:30 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexandru Ardelean X-Patchwork-Id: 8971191 X-Patchwork-Delegate: herbert@gondor.apana.org.au Return-Path: X-Original-To: patchwork-linux-crypto@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id DAF0DBF29F for ; Thu, 28 Apr 2016 14:15:39 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id C8340202AE for ; Thu, 28 Apr 2016 14:15:38 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 89BD22027D for ; Thu, 28 Apr 2016 14:15:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752270AbcD1OPg (ORCPT ); Thu, 28 Apr 2016 10:15:36 -0400 Received: from mail-wm0-f67.google.com ([74.125.82.67]:33602 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752195AbcD1OPg (ORCPT ); Thu, 28 Apr 2016 10:15:36 -0400 Received: by mail-wm0-f67.google.com with SMTP id r12so23951439wme.0 for ; Thu, 28 Apr 2016 07:15:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=Z6rHYt7gm/bIySt8o8Kkr0r7La0w5hmcfjqmlCNDh3w=; b=FAPymGx71/2R1gDeqSkPdReEWz4eVEyOZ81Kc4oNcXk6q6+0oPi8vaewYFCRaz+vZY bJdFjovXx7csJHwaIsfoAVR9xs1T8OvQIqTFYnX8pq4WiN63hXGiCsNIWrP9f+30ju8E RlKyf8Kk1NX9cVrXVuUI55i5XLAZTl3Z5Yq3BzAUN18Zr3AfCJa5Hj4mFRF6B1t2B8xA S0yKE44Tnaj/9v9Fgp1LqoCSORbXbMfvXpuPvoQmOBtqpxC99NU7mKdb1YTyfQW8U73I 0k8JSdO6pcSiSbXuTf1dHRp/2IxE664JHTmTNywm3seVpitJ4meMUxcnL7pD3SVDO/Vl VC3w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=Z6rHYt7gm/bIySt8o8Kkr0r7La0w5hmcfjqmlCNDh3w=; b=O91v6i3WEQsO/HmHtrqBFphoDssxhUl4FiOZw/+rPWZePx2gRW7IlyFjRMtrUp3NOY J/cDW6Sggwj6MG0SntACuxf3V6D2Fcswz+XL0Bs049ZD1eqpRi8OXc7TjRtJa4tti9OE 1jgzCUcZL2FD2kb/hTC3F761M5ibtiuv7Rju12GUQibL31iHJmry8K1YfzJstvJEBk5B F9IKAA46h3Vgx0QzDXL1KuXgpAWsVtJEEJBLNzSevekjoIQVlIwuAjhZsRN8npckerZm Uraj3WTK61GmuvDwwIfmNwYzTS/R/6+4juRTXQbHg+pQ7uA4fiuo9dtTfw0uoq9EmHSQ MmFA== X-Gm-Message-State: AOPr4FXNEkbud/6lXt3LMai/x3+xwhUdZBNMISsTSW2V53oMftoW1CJwJVedb+8QEuS6cw== X-Received: by 10.28.227.130 with SMTP id a124mr17289475wmh.2.1461852934434; Thu, 28 Apr 2016 07:15:34 -0700 (PDT) Received: from localhost.localdomain ([5.2.198.78]) by smtp.gmail.com with ESMTPSA id jo6sm9860052wjb.48.2016.04.28.07.15.33 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 28 Apr 2016 07:15:33 -0700 (PDT) From: Alexandru Ardelean X-Google-Original-From: Alexandru Ardelean To: linux-crypto@vger.kernel.org Cc: Alexandru Ardelean , Alexandru Ardelean Subject: [PATCH] crypto: talitos: fix driver init Date: Thu, 28 Apr 2016 17:15:30 +0300 Message-Id: <1461852930-714-1-git-send-email-aardelean@riverbed.com> X-Mailer: git-send-email 2.8.1 Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org X-Spam-Status: No, score=-7.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Alexandru Ardelean Crypto hash algorithms must provide the statesize sometime from kernel 4.2 onwards. Since commit 8996eafdcbad149ac0f772fb1649fbb75c482a6a Signed-off-by: Alexandru Ardelean --- drivers/crypto/talitos.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/crypto/talitos.c b/drivers/crypto/talitos.c index aae0554..080e329 100644 --- a/drivers/crypto/talitos.c +++ b/drivers/crypto/talitos.c @@ -2458,6 +2458,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = MD5_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "md5", .cra_driver_name = "md5-talitos", @@ -2473,6 +2474,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = SHA1_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "sha1", .cra_driver_name = "sha1-talitos", @@ -2488,6 +2490,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = SHA224_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "sha224", .cra_driver_name = "sha224-talitos", @@ -2503,6 +2506,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = SHA256_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "sha256", .cra_driver_name = "sha256-talitos", @@ -2518,6 +2522,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = SHA384_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "sha384", .cra_driver_name = "sha384-talitos", @@ -2533,6 +2538,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = SHA512_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "sha512", .cra_driver_name = "sha512-talitos", @@ -2548,6 +2554,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = MD5_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "hmac(md5)", .cra_driver_name = "hmac-md5-talitos", @@ -2563,6 +2570,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = SHA1_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "hmac(sha1)", .cra_driver_name = "hmac-sha1-talitos", @@ -2578,6 +2586,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = SHA224_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "hmac(sha224)", .cra_driver_name = "hmac-sha224-talitos", @@ -2593,6 +2602,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = SHA256_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "hmac(sha256)", .cra_driver_name = "hmac-sha256-talitos", @@ -2608,6 +2618,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = SHA384_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "hmac(sha384)", .cra_driver_name = "hmac-sha384-talitos", @@ -2623,6 +2634,7 @@ static struct talitos_alg_template driver_algs[] = { { .type = CRYPTO_ALG_TYPE_AHASH, .alg.hash = { .halg.digestsize = SHA512_DIGEST_SIZE, + .halg.statesize = sizeof(struct talitos_ahash_req_ctx), .halg.base = { .cra_name = "hmac(sha512)", .cra_driver_name = "hmac-sha512-talitos",