提交 fa649664 编写于 作者: H Herbert Xu

crypto: shash - Fix digest size offset

When an shash algorithm is exported as ahash, ahash will access
its digest size through hash_alg_common.  That's why the shash
layout needs to match hash_alg_common.  This wasn't the case
because the alignment weren't identical.

This patch fixes the problem.
Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
上级 a70c5225
......@@ -75,7 +75,8 @@ struct shash_alg {
unsigned int descsize;
/* These fields must match hash_alg_common. */
unsigned int digestsize;
unsigned int digestsize
__attribute__ ((aligned(__alignof__(struct hash_alg_common))));
unsigned int statesize;
struct crypto_alg base;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册