Commit 32a9fd8f authored by Herbert Xu's avatar Herbert Xu
Browse files

crypto: shash - Set reqsize in shash_alg



Make reqsize static for shash algorithms.

Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 8cf4c341
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -286,7 +286,6 @@ static int crypto_init_ahash_using_shash(struct crypto_tfm *tfm)

	crypto_ahash_set_flags(crt, crypto_shash_get_flags(shash) &
				    CRYPTO_TFM_NEED_KEY);
	crt->reqsize = sizeof(struct shash_desc) + crypto_shash_descsize(shash);

	return 0;
}
+2 −0
Original line number Diff line number Diff line
@@ -511,6 +511,8 @@ static int shash_prepare_alg(struct shash_alg *alg)
	if (alg->statesize > HASH_MAX_STATESIZE)
		return -EINVAL;

	base->cra_reqsize = sizeof(struct shash_desc) + alg->descsize;

	return 0;
}