ARM: 9136/1: ARMv7-M uses BE-8, not BE-32
authorArnd Bergmann <arnd@arndb.de>
Mon, 18 Oct 2021 14:30:06 +0000 (15:30 +0100)
committerRussell King (Oracle) <rmk+kernel@armlinux.org.uk>
Mon, 25 Oct 2021 12:12:33 +0000 (13:12 +0100)
commit345dac33f58894a56d17b92a41be10e16585ceff
treef11f54766e27fffc3054aefdf4c08e9cd77e9d1d
parent3583ab228a30b7c3fc8dd76ae45af7e25436b587
ARM: 9136/1: ARMv7-M uses BE-8, not BE-32

When configuring the kernel for big-endian, we set either BE-8 or BE-32
based on the CPU architecture level. Until linux-4.4, we did not have
any ARMv7-M platform allowing big-endian builds, but now i.MX/Vybrid
is in that category, adn we get a build error because of this:

arch/arm/kernel/module-plts.c: In function 'get_module_plt':
arch/arm/kernel/module-plts.c:60:46: error: implicit declaration of function '__opcode_to_mem_thumb32' [-Werror=implicit-function-declaration]

This comes down to picking the wrong default, ARMv7-M uses BE8
like ARMv7-A does. Changing the default gets the kernel to compile
and presumably works.

https://lore.kernel.org/all/1455804123-2526139-2-git-send-email-arnd@arndb.de/

Tested-by: Vladimir Murzin <vladimir.murzin@arm.com>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
arch/arm/mm/Kconfig