Re: [PATCH] crypto: clear htmldocs build warnings for crypto/hash
From: Herbert Xu
Date: Tue Jan 09 2018 - 02:42:02 EST
On Mon, Jan 08, 2018 at 05:43:18PM +0100, Kamil Konieczny wrote:
> Is it mandatory for both async hash and shash ?
>
> in crypto/ahash.c in function
>
> static int crypto_ahash_init_tfm(struct crypto_tfm *tfm)
>
> there is:
>
> hash->export = ahash_no_export;
> hash->import = ahash_no_import;
>
> and later in the same function:
>
> if (alg->export)
> hash->export = alg->export;
> if (alg->import)
> hash->import = alg->import;
That's just a leftover from the old days before we started requiring
them. These should be removed so that the registration fails if
they're not provided.
The requirement has been in place for a while now and we have been
failing any algorithms with a zero statesize which is only used by
import/export.
Thanks,
--
Email: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt