lib/crc: make the CPU feature static keys __ro_after_init
authorEric Biggers <ebiggers@google.com>
Sun, 13 Apr 2025 15:43:50 +0000 (08:43 -0700)
committerEric Biggers <ebiggers@google.com>
Mon, 28 Apr 2025 16:07:19 +0000 (09:07 -0700)
commit7ef377c4d4abb7a2a74fc319dc1bce46f2449af7
treef1987e24ba30028dce419edb20a3133b127be67f
parent8ffd015db85fea3e15a77027fda6c02ced4d2444
lib/crc: make the CPU feature static keys __ro_after_init

All of the CRC library's CPU feature static_keys are initialized by
initcalls and never change afterwards, so there's no need for them to be
in the regular .data section.  Put them in .data..ro_after_init instead.

Reviewed-by: "Martin K. Petersen" <martin.petersen@oracle.com>
Acked-by: Ard Biesheuvel <ardb@kernel.org>
Acked-by: Heiko Carstens <hca@linux.ibm.com> # s390
Link: https://lore.kernel.org/r/20250413154350.10819-1-ebiggers@kernel.org
Signed-off-by: Eric Biggers <ebiggers@google.com>
12 files changed:
arch/arm/lib/crc-t10dif-glue.c
arch/arm/lib/crc32-glue.c
arch/arm64/lib/crc-t10dif-glue.c
arch/loongarch/lib/crc32-loongarch.c
arch/mips/lib/crc32-mips.c
arch/powerpc/lib/crc-t10dif-glue.c
arch/powerpc/lib/crc32-glue.c
arch/s390/lib/crc32-glue.c
arch/sparc/lib/crc32_glue.c
arch/x86/lib/crc-t10dif-glue.c
arch/x86/lib/crc32-glue.c
arch/x86/lib/crc64-glue.c