Message ID | 20190805170037.31330-10-ard.biesheuvel@linaro.org |
---|---|
State | Superseded |
Headers | show
Delivered-To: patch@linaro.org Received: by 2002:a92:512:0:0:0:0:0 with SMTP id q18csp4537605ile; Mon, 5 Aug 2019 10:01:37 -0700 (PDT) X-Google-Smtp-Source: APXvYqwDxNV/jJFSEF7abH3jKOw9mTzo/0KZxajneK8WPreC2lcXHQ5aEfbyr+08J1Yc7UDKbu4y X-Received: by 2002:a17:90a:214e:: with SMTP id a72mr19762509pje.0.1565024497354; Mon, 05 Aug 2019 10:01:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565024497; cv=none; d=google.com; s=arc-20160816; b=A7OHdtAdzhgoOFXOjMBM0VQ7E+25hoNGYhQr50hD2LNQCnNxAxOlZU1M50wnIgs5IF LSx3+kpSzNIMijALONi4osuyZJ4IZeiD5Ho4ORVg/wxJYRT8gPIeJ2akFNrtaPWTwPZJ 3Q1ayBdvy4hp75dSsk7R1bCz2+4mYfm9gGJp97V+g4NtgQeOGYwslvlQdKW+Glx4wWr0 0YPbkIDMSLlSjrNUgJpxpHneDRZ4dBKymYQgRj/r3ORXVD3Z1mX21m/VafO9g8VDeMGY /qVALQ7/u+lmmuVh0DBu2fZq3+gthiR+ZU5+rrlweDphavjYpeCFATTkPiiGFITqHQnk 5kNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=XCfq0cibkHau/c01ce7pT9k2NNgLItL6s6kRL+GZ0sg=; b=Zf/JpZlM7jxq2CFfBiWu6mqsu6M5pSFZksmc5YaYcvzC+wdfbCJPUzXOI7jQd+67k7 scWYAGl9BrfYI5Zvof78Y3WK1ALa7as5F6CROQSe10hwE2d0w3IGOHGZnrtHWVIveqAU z0zBMJovkZL+8zAddz7LTQNhW3N6Xphf0z2aXf5/XkpEnknPvPbRjIZaovu+p9RKChUS HsYjSHctK6WBjZR/edeln4VVPu+lfBV8TvG+8GR8JWL6MHXCBbJpO9vgeC4tEw8vfNsx dEaIKG/U+ezMeyK21bYZ0VCzFfSE2mBHugAG3y0jkIk3dsAfRWEf8ZME6BsIcbKyGE4/ Bkzg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZxWYPB0J; spf=pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: <linux-crypto-owner@vger.kernel.org> Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b61si41087117plb.401.2019.08.05.10.01.37; Mon, 05 Aug 2019 10:01:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZxWYPB0J; spf=pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729469AbfHERBg (ORCPT <rfc822;sumit.garg@linaro.org> + 3 others); Mon, 5 Aug 2019 13:01:36 -0400 Received: from mail-wm1-f65.google.com ([209.85.128.65]:36738 "EHLO mail-wm1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728871AbfHERBg (ORCPT <rfc822;linux-crypto@vger.kernel.org>); Mon, 5 Aug 2019 13:01:36 -0400 Received: by mail-wm1-f65.google.com with SMTP id g67so69612330wme.1 for <linux-crypto@vger.kernel.org>; Mon, 05 Aug 2019 10:01:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=XCfq0cibkHau/c01ce7pT9k2NNgLItL6s6kRL+GZ0sg=; b=ZxWYPB0JbZ63jNF90t31kYWxWInvUzFns9iIdrBnjJ9VOvQ8O0i3pjYdJ08edr3C4r gkPcBsr7ZSmbb48Sd5i8Jf12Cg7lHXMPZgVaM2uW4lMFplB3jvxWSV3ZZQtZxO4Nlc6R FlkWEeDKxYt1iU9FXHlp6hCT0pvCJ9XATk6kYVM0NJ1VE/afZRGvU4RHZmXyVRzSimZV j7s/fCJJ3brDJeLzdcwt/tEc5raoavH4s1gKBTgp46IbIGrQ8yr49kyJpjd9N34VUjjJ dLiIm2kQ8ztoGzytlBLsXsIZOaEQg0PDHwdF/BiBJv+e3Xj5IEesR8Nx1Jr7rcmbbDKc wv2g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=XCfq0cibkHau/c01ce7pT9k2NNgLItL6s6kRL+GZ0sg=; b=Zo+VxpOqL6DvOlpLBhGn0vW7ydKGhgCQLb4phSaVb0KgEi6xPvJRDOgXm12zAYKYiv McHzMPbgUAuLjiU8C3e/l+4JMCE+w3lfQHN++JRvQyPTNsU3eeLX+V0KvUeL1/cffe4f myQ52DLm+O9qv3itzbkv1+Q3y+TmGrY27JXac8ZChuPZKXSNKd+LDeJ6CT3so4Kt005W o3wv5UgzcZ3MwQ/9oZaTCpONjMdFr3PF9masRAL2E3avP82vFssx761IZLP4Dk32tu/D lI7Q4/uAcoe0cL2Oegh5uvGtlxVTKemkXnfThiWNDoPdFD3YHtDMdgiM3+Rg0XIEmExr L51A== X-Gm-Message-State: APjAAAUH+CCmubH+03uS96p+UrGub8Wgj4p6qZ62B6ycCCj8nA90DQzC o+ldDZURujRBJa57HW6AIhy/dLJSPzTP/g== X-Received: by 2002:a7b:c7cb:: with SMTP id z11mr17844972wmk.24.1565024494514; Mon, 05 Aug 2019 10:01:34 -0700 (PDT) Received: from localhost.localdomain ([2a02:587:a407:da00:582f:8334:9cd9:7241]) by smtp.gmail.com with ESMTPSA id j9sm95669383wrn.81.2019.08.05.10.01.29 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 05 Aug 2019 10:01:33 -0700 (PDT) From: Ard Biesheuvel <ard.biesheuvel@linaro.org> To: linux-crypto@vger.kernel.org Cc: herbert@gondor.apana.org.au, ebiggers@kernel.org, horia.geanta@nxp.com, Ard Biesheuvel <ard.biesheuvel@linaro.org> Subject: [PATCH v4 09/30] crypto: ccp/des - switch to new verification routines Date: Mon, 5 Aug 2019 20:00:16 +0300 Message-Id: <20190805170037.31330-10-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190805170037.31330-1-ard.biesheuvel@linaro.org> References: <20190805170037.31330-1-ard.biesheuvel@linaro.org> Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: <linux-crypto.vger.kernel.org> X-Mailing-List: linux-crypto@vger.kernel.org |
Series |
crypto: DES/3DES cleanup
|
expand
|
diff --git a/drivers/crypto/ccp/ccp-crypto-des3.c b/drivers/crypto/ccp/ccp-crypto-des3.c index 5f05f834c7cd..cbcdf1b5971f 100644 --- a/drivers/crypto/ccp/ccp-crypto-des3.c +++ b/drivers/crypto/ccp/ccp-crypto-des3.c @@ -14,7 +14,7 @@ #include <linux/crypto.h> #include <crypto/algapi.h> #include <crypto/scatterwalk.h> -#include <crypto/des.h> +#include <crypto/internal/des.h> #include "ccp-crypto.h" @@ -39,11 +39,10 @@ static int ccp_des3_setkey(struct crypto_ablkcipher *tfm, const u8 *key, struct ccp_ctx *ctx = crypto_tfm_ctx(crypto_ablkcipher_tfm(tfm)); struct ccp_crypto_ablkcipher_alg *alg = ccp_crypto_ablkcipher_alg(crypto_ablkcipher_tfm(tfm)); - u32 *flags = &tfm->base.crt_flags; int err; - err = __des3_verify_key(flags, key); - if (unlikely(err)) + err = crypto_des3_ede_verify_key(crypto_ablkcipher_tfm(tfm), key); + if (err) return err; /* It's not clear that there is any support for a keysize of 112.
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> --- drivers/crypto/ccp/ccp-crypto-des3.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) -- 2.17.1