Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c87a405e authored by Eric Biggers's avatar Eric Biggers Committed by Herbert Xu
Browse files

crypto: ahash - remove useless setting of cra_type



Some ahash algorithms set .cra_type = &crypto_ahash_type.  But this is
redundant with the C structure type ('struct ahash_alg'), and
crypto_register_ahash() already sets the .cra_type automatically.
Apparently the useless assignment has just been copy+pasted around.

So, remove the useless assignment from all the ahash algorithms.

This patch shouldn't change any actual behavior.

Signed-off-by: default avatarEric Biggers <ebiggers@google.com>
Acked-by: default avatarGilad Ben-Yossef <gilad@benyossef.com>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 6a38f622
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -310,7 +310,6 @@ static struct ahash_alg ghash_async_alg = {
		.cra_priority	= 300,
		.cra_flags	= CRYPTO_ALG_ASYNC,
		.cra_blocksize	= GHASH_BLOCK_SIZE,
		.cra_type	= &crypto_ahash_type,
		.cra_ctxsize	= sizeof(struct ghash_async_ctx),
		.cra_module	= THIS_MODULE,
		.cra_init	= ghash_async_init_tfm,
+0 −1
Original line number Diff line number Diff line
@@ -316,7 +316,6 @@ static struct ahash_alg ghash_async_alg = {
			.cra_ctxsize		= sizeof(struct ghash_async_ctx),
			.cra_flags		= CRYPTO_ALG_ASYNC,
			.cra_blocksize		= GHASH_BLOCK_SIZE,
			.cra_type		= &crypto_ahash_type,
			.cra_module		= THIS_MODULE,
			.cra_init		= ghash_async_init_tfm,
			.cra_exit		= ghash_async_exit_tfm,
+0 −1
Original line number Diff line number Diff line
@@ -880,7 +880,6 @@ static struct ahash_alg sha1_mb_async_alg = {
			.cra_priority           = 50,
			.cra_flags              = CRYPTO_ALG_ASYNC,
			.cra_blocksize          = SHA1_BLOCK_SIZE,
			.cra_type               = &crypto_ahash_type,
			.cra_module             = THIS_MODULE,
			.cra_list               = LIST_HEAD_INIT(sha1_mb_async_alg.halg.base.cra_list),
			.cra_init               = sha1_mb_async_init_tfm,
+0 −1
Original line number Diff line number Diff line
@@ -879,7 +879,6 @@ static struct ahash_alg sha256_mb_async_alg = {
			.cra_priority           = 50,
			.cra_flags              = CRYPTO_ALG_ASYNC,
			.cra_blocksize          = SHA256_BLOCK_SIZE,
			.cra_type               = &crypto_ahash_type,
			.cra_module             = THIS_MODULE,
			.cra_list               = LIST_HEAD_INIT
				(sha256_mb_async_alg.halg.base.cra_list),
+0 −1
Original line number Diff line number Diff line
@@ -913,7 +913,6 @@ static struct ahash_alg sha512_mb_async_alg = {
			.cra_priority           = 50,
			.cra_flags              = CRYPTO_ALG_ASYNC,
			.cra_blocksize          = SHA512_BLOCK_SIZE,
			.cra_type               = &crypto_ahash_type,
			.cra_module             = THIS_MODULE,
			.cra_list               = LIST_HEAD_INIT
				(sha512_mb_async_alg.halg.base.cra_list),
Loading