diff options
author | Antoine Ténart <antoine.tenart@free-electrons.com> | 2017-06-01 21:38:56 +0200 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2017-06-19 14:19:50 +0800 |
commit | 0f52ddaed6500d0b74fcaf5568726068d385129f (patch) | |
tree | d18c3fb84345a9ba3a84fcc8011fd89f867c60e3 /drivers | |
parent | 11be0107ab1a893121ff31325e1bf82d843ea4dc (diff) | |
download | linux-0f52ddaed6500d0b74fcaf5568726068d385129f.tar.bz2 |
crypto: sun4i-ss - cannot use DMA is the request is 0 length
Do not use DMA is the request is 0 length.
Signed-off-by: Antoine Tenart <antoine.tenart@free-electrons.com>
Tested-by: Corentin Labbe <clabbe.montjoie@gmail.com>
Acked-by: Corentin Labbe <clabbe.montjoie@gmail.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/crypto/sunxi-ss/sun4i-ss-hash.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/crypto/sunxi-ss/sun4i-ss-hash.c b/drivers/crypto/sunxi-ss/sun4i-ss-hash.c index e53c3127b743..bc3cbde07219 100644 --- a/drivers/crypto/sunxi-ss/sun4i-ss-hash.c +++ b/drivers/crypto/sunxi-ss/sun4i-ss-hash.c @@ -250,7 +250,7 @@ static int sun4i_hash(struct ahash_request *areq) i = 0; in_sg = sg_next(in_sg); } - if (i == 1 && !op->len) + if (i == 1 && !op->len && areq->nbytes) dev_dbg(ss->dev, "We can DMA\n"); i = 0; |