LoongArch: Fix module relocation error with binutils 2.41
authorHuacai Chen <chenhuacai@loongson.cn>
Fri, 28 Jul 2023 02:30:42 +0000 (10:30 +0800)
committerHuacai Chen <chenhuacai@loongson.cn>
Fri, 28 Jul 2023 02:30:42 +0000 (10:30 +0800)
commit03c53eb90c0c61885b2175adf8675fb56df7f8db
tree4fdcde097f51ca2ebabb67114a1d5032b936e995
parent54c2c9df083fe1d4a9df54d9876f32582ce6d77a
LoongArch: Fix module relocation error with binutils 2.41

Binutils 2.41 enables linker relaxation by default, but the kernel
module loader doesn't support that, so just disable it. Otherwise we
get such an error when loading modules:

"Unknown relocation type 102"

As an alternative, we could add linker relaxation support in the kernel
module loader. But it is relatively large complexity that may or may not
bring a similar gain, and we don't really want to include this linker
pass in the kernel.

Reviewed-by: WANG Xuerui <git@xen0n.name>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
arch/loongarch/Makefile