diff options
author | Fabio Estevam <fabio.estevam@nxp.com> | 2016-02-03 10:46:52 -0200 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2016-02-06 15:33:29 +0800 |
commit | d42cf2f1901e4fafb133d5fb680fc7138b9ba393 (patch) | |
tree | d1feff4681188b30817e323f408e45e932151dc9 /drivers/crypto/sahara.c | |
parent | bceab44eed7f37110136860cb2992fbd6702588d (diff) | |
download | linux-d42cf2f1901e4fafb133d5fb680fc7138b9ba393.tar.gz linux-d42cf2f1901e4fafb133d5fb680fc7138b9ba393.tar.bz2 linux-d42cf2f1901e4fafb133d5fb680fc7138b9ba393.zip |
crypto: sahara - fill the statesize field
Currently the sahara driver fails to probe:
sahara: probe of 63ff8000.crypto failed with error -22
This happens since commit 8996eafdcbad ("crypto: ahash - ensure statesize
is non-zero"), which requires statesize to be filled.
Pass the statesize members for sha1 and sha256, so we can probe
the driver successfully again.
Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/sahara.c')
-rw-r--r-- | drivers/crypto/sahara.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/crypto/sahara.c b/drivers/crypto/sahara.c index 9db09b643a44..c3f3d89e4831 100644 --- a/drivers/crypto/sahara.c +++ b/drivers/crypto/sahara.c @@ -1259,6 +1259,7 @@ static struct ahash_alg sha_v3_algs[] = { .export = sahara_sha_export, .import = sahara_sha_import, .halg.digestsize = SHA1_DIGEST_SIZE, + .halg.statesize = sizeof(struct sahara_sha_reqctx), .halg.base = { .cra_name = "sha1", .cra_driver_name = "sahara-sha1", @@ -1286,6 +1287,7 @@ static struct ahash_alg sha_v4_algs[] = { .export = sahara_sha_export, .import = sahara_sha_import, .halg.digestsize = SHA256_DIGEST_SIZE, + .halg.statesize = sizeof(struct sahara_sha_reqctx), .halg.base = { .cra_name = "sha256", .cra_driver_name = "sahara-sha256", |