projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ff455ad
)
crypto: caam - print IV only when non NULL
author
Sascha Hauer
<s.hauer@pengutronix.de>
Thu, 23 May 2019 08:50:27 +0000
(10:50 +0200)
committer
Herbert Xu
<herbert@gondor.apana.org.au>
Thu, 30 May 2019 07:30:30 +0000
(15:30 +0800)
Since
eaed71a44ad9
("crypto: caam - add ecb(*) support") the IV can be
NULL, so only dump it when it's non NULL as designated by the ivsize
variable.
Fixes: eaed71a44ad9 ("crypto: caam - add ecb(*) support")
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/caam/caamalg.c
patch
|
blob
|
history
diff --git
a/drivers/crypto/caam/caamalg.c
b/drivers/crypto/caam/caamalg.c
index 08c36ae5d12d12e0afbf089b7789ef1d46a886ae..3a64f74dbdced4d466d56bff547e2ebdb7ac430f 100644
(file)
--- a/
drivers/crypto/caam/caamalg.c
+++ b/
drivers/crypto/caam/caamalg.c
@@
-1021,9
+1021,10
@@
static void skcipher_encrypt_done(struct device *jrdev, u32 *desc, u32 err,
ivsize, ivsize, 0);
#ifdef DEBUG
- print_hex_dump(KERN_ERR, "dstiv @"__stringify(__LINE__)": ",
- DUMP_PREFIX_ADDRESS, 16, 4, req->iv,
- edesc->src_nents > 1 ? 100 : ivsize, 1);
+ if (ivsize)
+ print_hex_dump(KERN_ERR, "dstiv @"__stringify(__LINE__)": ",
+ DUMP_PREFIX_ADDRESS, 16, 4, req->iv,
+ edesc->src_nents > 1 ? 100 : ivsize, 1);
#endif
caam_dump_sg(KERN_ERR, "dst @" __stringify(__LINE__)": ",
DUMP_PREFIX_ADDRESS, 16, 4, req->dst,