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

Commit 4b9eee96 authored by Ard Biesheuvel's avatar Ard Biesheuvel Committed by Linus Torvalds
Browse files

module: unify absolute krctab definitions for 32-bit and 64-bit



The previous patch introduced a separate inline asm version of the
krcrctab declaration template for use with 64-bit architectures, which
cannot refer to ELF symbols using 32-bit quantities.

This declaration should be equivalent to the C one for 32-bit
architectures, but just in case - unify them in a separate patch, which
can simply be dropped if it turns out to break anything.

Signed-off-by: default avatarArd Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 71810db2
Loading
Loading
Loading
Loading
+0 −7
Original line number Original line Diff line number Diff line
@@ -49,13 +49,6 @@ extern struct module __this_module;
	    "	.weak	" VMLINUX_SYMBOL_STR(__crc_##sym) "	\n"	\
	    "	.weak	" VMLINUX_SYMBOL_STR(__crc_##sym) "	\n"	\
	    "	.long	" VMLINUX_SYMBOL_STR(__crc_##sym) " - .	\n"	\
	    "	.long	" VMLINUX_SYMBOL_STR(__crc_##sym) " - .	\n"	\
	    "	.previous					\n");
	    "	.previous					\n");
#elif !defined(CONFIG_64BIT)
#define __CRC_SYMBOL(sym, sec)						\
	extern __visible void *__crc_##sym __attribute__((weak));	\
	static const unsigned long __kcrctab_##sym			\
	__used								\
	__attribute__((section("___kcrctab" sec "+" #sym), used))	\
	= (unsigned long) &__crc_##sym;
#else
#else
#define __CRC_SYMBOL(sym, sec)						\
#define __CRC_SYMBOL(sym, sec)						\
	asm("	.section \"___kcrctab" sec "+" #sym "\", \"a\"	\n"	\
	asm("	.section \"___kcrctab" sec "+" #sym "\", \"a\"	\n"	\