MIPS: Support binutils configured with --enable-mips-fix-loongson3-llsc=yes
authorAurelien Jarno <aurelien@aurel32.net>
Sat, 9 Jan 2021 19:30:47 +0000 (20:30 +0100)
committerThomas Bogendoerfer <tsbogend@alpha.franken.de>
Fri, 15 Jan 2021 14:34:20 +0000 (15:34 +0100)
commit5373ae67c3aad1ab306cc722b5a80b831eb4d4d1
treef8b46e8326f9ef4efde53cea2dd97d84dd28c608
parent8790ccf8daf1a8c53b6cb8ce0c9a109274bd3fa8
MIPS: Support binutils configured with --enable-mips-fix-loongson3-llsc=yes

From version 2.35, binutils can be configured with
--enable-mips-fix-loongson3-llsc=yes, which means it defaults to
-mfix-loongson3-llsc. This breaks labels which might then point at the
wrong instruction.

The workaround to explicitly pass -mno-fix-loongson3-llsc has been
added in Linux version 5.1, but is only enabled when building a Loongson
64 kernel. As vendors might use a common toolchain for building Loongson
and non-Loongson kernels, just move that workaround to
arch/mips/Makefile. At the same time update the comments to reflect the
current status.

Cc: stable@vger.kernel.org # 5.1+
Cc: YunQiang Su <syq@debian.org>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
arch/mips/Makefile
arch/mips/loongson64/Platform