kernel_samsung_a53x/arch/arm/crypto
Arnd Bergmann a181e0709b crypto: arm/sha - fix function cast warnings
[ Upstream commit 53cc9baeb9bc2a187eb9c9790d30995148852b12 ]

clang-16 warns about casting between incompatible function types:

arch/arm/crypto/sha256_glue.c:37:5: error: cast from 'void (*)(u32 *, const void *, unsigned int)' (aka 'void (*)(unsigned int *, const void *, unsigned int)') to 'sha256_block_fn *' (aka 'void (*)(struct sha256_state *, const unsigned char *, int)') converts to incompatible function type [-Werror,-Wcast-function-type-strict]
   37 |                                 (sha256_block_fn *)sha256_block_data_order);
      |                                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm/crypto/sha512-glue.c:34:3: error: cast from 'void (*)(u64 *, const u8 *, int)' (aka 'void (*)(unsigned long long *, const unsigned char *, int)') to 'sha512_block_fn *' (aka 'void (*)(struct sha512_state *, const unsigned char *, int)') converts to incompatible function type [-Werror,-Wcast-function-type-strict]
   34 |                 (sha512_block_fn *)sha512_block_data_order);
      |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Fix the prototypes for the assembler functions to match the typedef.
The code already relies on the digest being the first part of the
state structure, so there is no change in behavior.

Fixes: c80ae7ca3726 ("crypto: arm/sha512 - accelerated SHA-512 using ARM generic ASM and NEON")
Fixes: b59e2ae3690c ("crypto: arm/sha256 - move SHA-224/256 ASM/NEON implementation to base layer")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-19 08:44:54 +01:00
..
aes-ce-core.S
aes-ce-glue.c
aes-cipher-core.S
aes-cipher-glue.c
aes-neonbs-core.S
aes-neonbs-glue.c
blake2b-neon-core.S
blake2b-neon-glue.c
blake2s-core.S
blake2s-glue.c
blake2s-shash.c
chacha-glue.c
chacha-neon-core.S
chacha-scalar-core.S
crc32-ce-core.S
crc32-ce-glue.c
crct10dif-ce-core.S
crct10dif-ce-glue.c
curve25519-core.S
curve25519-glue.c
ghash-ce-core.S
ghash-ce-glue.c
Kconfig
Makefile
nh-neon-core.S
nhpoly1305-neon-glue.c
poly1305-armv4.pl
poly1305-core.S_shipped
poly1305-glue.c
sha1-armv4-large.S
sha1-armv7-neon.S
sha1-ce-core.S
sha1-ce-glue.c
sha1.h
sha1_glue.c
sha1_neon_glue.c
sha2-ce-core.S
sha2-ce-glue.c
sha256-armv4.pl
sha256-core.S_shipped
sha256_glue.c crypto: arm/sha - fix function cast warnings 2024-11-19 08:44:54 +01:00
sha256_glue.h
sha256_neon_glue.c
sha512-armv4.pl
sha512-core.S_shipped
sha512-glue.c crypto: arm/sha - fix function cast warnings 2024-11-19 08:44:54 +01:00
sha512-neon-glue.c
sha512.h