[PATCH] lib/crc: arm64: Fix const keyword in asm prototypes

From: Geert Uytterhoeven

Date: Thu Sep 03 2026 - 08:06:35 EST


Commit d36cebe03c3ae4ea ("lib/crc32: improve support for arch-specific
overrides") corrected the position of the "const" keyword in the
arch-specific funcions, and replaced "unsigned char" by "u8" for
consistency.

Make the same change to the forward declarations for the asm
implementations.

Signed-off-by: Geert Uytterhoeven <geert+renesas@xxxxxxxxx>
---
lib/crc/arm64/crc32.h | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/lib/crc/arm64/crc32.h b/lib/crc/arm64/crc32.h
index 1939a5dee4772972..332d9092ba2f3875 100644
--- a/lib/crc/arm64/crc32.h
+++ b/lib/crc/arm64/crc32.h
@@ -7,13 +7,13 @@
// The minimum input length to consider the 4-way interleaved code path
static const size_t min_len = 1024;

-asmlinkage u32 crc32_le_arm64(u32 crc, unsigned char const *p, size_t len);
-asmlinkage u32 crc32c_le_arm64(u32 crc, unsigned char const *p, size_t len);
-asmlinkage u32 crc32_be_arm64(u32 crc, unsigned char const *p, size_t len);
+asmlinkage u32 crc32_le_arm64(u32 crc, const u8 *p, size_t len);
+asmlinkage u32 crc32c_le_arm64(u32 crc, const u8 *p, size_t len);
+asmlinkage u32 crc32_be_arm64(u32 crc, const u8 *p, size_t len);

-asmlinkage u32 crc32_le_arm64_4way(u32 crc, unsigned char const *p, size_t len);
-asmlinkage u32 crc32c_le_arm64_4way(u32 crc, unsigned char const *p, size_t len);
-asmlinkage u32 crc32_be_arm64_4way(u32 crc, unsigned char const *p, size_t len);
+asmlinkage u32 crc32_le_arm64_4way(u32 crc, const u8 *p, size_t len);
+asmlinkage u32 crc32c_le_arm64_4way(u32 crc, const u8 *p, size_t len);
+asmlinkage u32 crc32_be_arm64_4way(u32 crc, const u8 *p, size_t len);

static inline u32 crc32_le_arch(u32 crc, const u8 *p, size_t len)
{
--
2.43.0