mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Corentin Labbe <clabbe.montjoie@gmail.com>
To: davem@davemloft.net, herbert@gondor.apana.org.au,
	maxime.ripard@bootlin.com, wens@csie.org
Cc: linux-arm-kernel@lists.infradead.org,
	linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-sunxi@googlegroups.com, ebiggers@kernel.org,
	Corentin Labbe <clabbe.montjoie@gmail.com>
Subject: [PATCH 1/4] crypto: sun4i-ss: Handle better absence/presence of IV
Date: Thu, 18 Apr 2019 10:17:32 +0200	[thread overview]
Message-ID: <20190418081735.19002-2-clabbe.montjoie@gmail.com> (raw)
In-Reply-To: <20190418081735.19002-1-clabbe.montjoie@gmail.com>

This patch remove the test against areq->info since sun4i-ss could work
without it (ECB).

Fixes: 6298e948215f ("crypto: sunxi-ss - Add Allwinner Security System crypto accelerator")
Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
---
 drivers/crypto/sunxi-ss/sun4i-ss-cipher.c | 10 ----------
 1 file changed, 10 deletions(-)

diff --git a/drivers/crypto/sunxi-ss/sun4i-ss-cipher.c b/drivers/crypto/sunxi-ss/sun4i-ss-cipher.c
index 06df336488fb..4b60f8fdd1c8 100644
--- a/drivers/crypto/sunxi-ss/sun4i-ss-cipher.c
+++ b/drivers/crypto/sunxi-ss/sun4i-ss-cipher.c
@@ -41,11 +41,6 @@ static int sun4i_ss_opti_poll(struct skcipher_request *areq)
 	if (!areq->cryptlen)
 		return 0;
 
-	if (!areq->iv) {
-		dev_err_ratelimited(ss->dev, "ERROR: Empty IV\n");
-		return -EINVAL;
-	}
-
 	if (!areq->src || !areq->dst) {
 		dev_err_ratelimited(ss->dev, "ERROR: Some SGs are NULL\n");
 		return -EINVAL;
@@ -157,11 +152,6 @@ static int sun4i_ss_cipher_poll(struct skcipher_request *areq)
 	if (!areq->cryptlen)
 		return 0;
 
-	if (!areq->iv) {
-		dev_err_ratelimited(ss->dev, "ERROR: Empty IV\n");
-		return -EINVAL;
-	}
-
 	if (!areq->src || !areq->dst) {
 		dev_err_ratelimited(ss->dev, "ERROR: Some SGs are NULL\n");
 		return -EINVAL;
-- 
2.21.0


  reply	other threads:[~2019-04-18  8:17 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-18  8:17 [PATCH 0/4] crypto: sun4i-ss: Fix problem reported by CONFIG_CRYPTO_EXTRA_TESTS Corentin Labbe
2019-04-18  8:17 ` Corentin Labbe [this message]
2019-04-18  8:17 ` [PATCH 2/4] crypto: sun4i-ss: remove ivsize from ECB Corentin Labbe
2019-04-18  8:17 ` [PATCH 3/4] crypto: sun4i-ss: Fix invalid calculation of hash end Corentin Labbe
2019-04-18  8:17 ` [PATCH 4/4] crypto: sun4i-ss: fallback when length is not multiple of blocksize Corentin Labbe
2019-04-25  7:50 ` [PATCH 0/4] crypto: sun4i-ss: Fix problem reported by CONFIG_CRYPTO_EXTRA_TESTS Herbert Xu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190418081735.19002-2-clabbe.montjoie@gmail.com \
    --to=clabbe.montjoie@gmail.com \
    --cc=davem@davemloft.net \
    --cc=ebiggers@kernel.org \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sunxi@googlegroups.com \
    --cc=maxime.ripard@bootlin.com \
    --cc=wens@csie.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®