OSDN Git Service
(root)
/
android-x86
/
kernel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
225ece3
)
crypto: sun4i_ss_prng - fix return value of sun4i_ss_prng_generate
author
Artem Savkov
<artem.savkov@gmail.com>
Tue, 6 Feb 2018 21:20:21 +0000
(22:20 +0100)
committer
Herbert Xu
<herbert@gondor.apana.org.au>
Thu, 8 Feb 2018 11:38:13 +0000
(22:38 +1100)
According to crypto/rng.h generate function should return 0 on success
and < 0 on error.
Fixes:
b8ae5c7387ad
("crypto: sun4i-ss - support the Security System PRNG")
Signed-off-by: Artem Savkov <artem.savkov@gmail.com>
Acked-by: Corentin Labbe <clabbe.montjoie@gmail.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/sunxi-ss/sun4i-ss-prng.c
patch
|
blob
|
history
diff --git
a/drivers/crypto/sunxi-ss/sun4i-ss-prng.c
b/drivers/crypto/sunxi-ss/sun4i-ss-prng.c
index
0d01d16
..
5754e0b
100644
(file)
--- a/
drivers/crypto/sunxi-ss/sun4i-ss-prng.c
+++ b/
drivers/crypto/sunxi-ss/sun4i-ss-prng.c
@@
-52,5
+52,5
@@
int sun4i_ss_prng_generate(struct crypto_rng *tfm, const u8 *src,
writel(0, ss->base + SS_CTL);
spin_unlock(&ss->slock);
- return
dlen
;
+ return
0
;
}