linux-stable/arch/arm
Nathan Chancellor 0ba942cbf5 crypto: arm/curve25519 - Move '.fpu' after '.arch'
commit 44200f2d9b upstream.

Debian's clang carries a patch that makes the default FPU mode
'vfp3-d16' instead of 'neon' for 'armv7-a' to avoid generating NEON
instructions on hardware that does not support them:

5a61ca6f21/debian/patches/clang-arm-default-vfp3-on-armv7a.patch
https://bugs.debian.org/841474
https://bugs.debian.org/842142
https://bugs.debian.org/914268

This results in the following build error when clang's integrated
assembler is used because the '.arch' directive overrides the '.fpu'
directive:

arch/arm/crypto/curve25519-core.S:25:2: error: instruction requires: NEON
 vmov.i32 q0, #1
 ^
arch/arm/crypto/curve25519-core.S:26:2: error: instruction requires: NEON
 vshr.u64 q1, q0, #7
 ^
arch/arm/crypto/curve25519-core.S:27:2: error: instruction requires: NEON
 vshr.u64 q0, q0, #8
 ^
arch/arm/crypto/curve25519-core.S:28:2: error: instruction requires: NEON
 vmov.i32 d4, #19
 ^

Shuffle the order of the '.arch' and '.fpu' directives so that the code
builds regardless of the default FPU mode. This has been tested against
both clang with and without Debian's patch and GCC.

Cc: stable@vger.kernel.org
Fixes: d8f1308a02 ("crypto: arm/curve25519 - wire up NEON implementation")
Link: https://github.com/ClangBuiltLinux/continuous-integration2/issues/118
Reported-by: Arnd Bergmann <arnd@arndb.de>
Suggested-by: Arnd Bergmann <arnd@arndb.de>
Suggested-by: Jessica Clarke <jrtc27@jrtc27.com>
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
Acked-by: Jason A. Donenfeld <Jason@zx2c4.com>
Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
Tested-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-05-11 14:47:35 +02:00
..
boot ARM: dts: at91: change the key code of the gpio key 2021-05-11 14:47:20 +02:00
common ARM/sa1111: add a missing include of dma-map-ops.h 2020-10-20 09:40:33 +02:00
configs mm/zsmalloc.c: drop ZSMALLOC_PGTABLE_MAPPING 2020-12-06 10:19:07 -08:00
crypto crypto: arm/curve25519 - Move '.fpu' after '.arch' 2021-05-11 14:47:35 +02:00
include ARM: assembler: introduce adr_l, ldr_l and str_l macros 2021-03-17 17:06:26 +01:00
kernel ARM: 9029/1: Make iwmmxt.S support Clang's integrated assembler 2021-03-17 17:06:26 +01:00
lib
mach-actions
mach-alpine
mach-artpec
mach-asm9260
mach-aspeed
mach-at91 ARM: at91: use proper asm syntax in pm_suspend 2021-03-04 11:37:28 +01:00
mach-axxia
mach-bcm
mach-berlin
mach-clps711x
mach-cns3xxx
mach-davinci ARM: SoC platform updates 2020-10-24 10:33:08 -07:00
mach-digicolor
mach-dove
mach-ebsa110
mach-efm32
mach-ep93xx
mach-exynos Samsung mach/soc changes for v5.10 2020-09-26 12:55:43 -07:00
mach-footbridge ARM: footbridge: fix PCI interrupt mapping 2021-04-21 13:00:58 +02:00
mach-gemini
mach-highbank dma-mapping: split <linux/dma-mapping.h> 2020-10-06 07:07:03 +02:00
mach-hisi ARM: hisi: add support for SD5203 SoC 2020-09-30 09:56:03 +08:00
mach-imx ARM: imx: build suspend-imx6.S with arm instruction set 2021-02-03 23:28:44 +01:00
mach-integrator
mach-iop32x
mach-ixp4xx clocksource/drivers/ixp4xx: Select TIMER_OF when needed 2021-03-04 11:37:57 +01:00
mach-keystone ARM: keystone: fix integer overflow warning 2021-04-21 13:00:52 +02:00
mach-lpc18xx
mach-lpc32xx
mach-mediatek
mach-meson
mach-milbeaut
mach-mmp
mach-moxart
mach-mstar ARM: mstar: Select MStar intc 2020-10-03 12:47:56 -07:00
mach-mv78xx0
mach-mvebu mvebu fixes for 5.9 (part 1) 2020-10-26 10:11:55 +01:00
mach-mxs
mach-nomadik
mach-npcm
mach-nspire
mach-omap1 ARM: omap1: fix building with clang IAS 2021-04-21 13:00:52 +02:00
mach-omap2 ARM: OMAP2+: Fix uninitialized sr_inst 2021-04-21 13:00:59 +02:00
mach-orion5x
mach-oxnas
mach-picoxcell
mach-prima2
mach-pxa power: supply: gpio-charger: Convert to GPIO descriptors 2020-08-27 16:47:14 +02:00
mach-qcom
mach-rda
mach-realtek
mach-realview
mach-rockchip
mach-rpc
mach-s3c ARM: s3c: fix fiq for clang IAS 2021-03-04 11:37:28 +01:00
mach-s5pv210
mach-sa1100 power: supply: gpio-charger: Convert to GPIO descriptors 2020-08-27 16:47:14 +02:00
mach-shmobile ARM: SoC platform updates 2020-10-24 10:33:08 -07:00
mach-socfpga
mach-spear
mach-sti
mach-stm32 ARM: stm32: Replace HTTP links with HTTPS ones 2020-10-03 12:38:54 -07:00
mach-sunxi ARM: sunxi: Add machine match for the Allwinner V3 SoC 2020-11-02 10:28:14 +01:00
mach-tango
mach-tegra
mach-u300
mach-uniphier
mach-ux500
mach-versatile
mach-vexpress
mach-vt8500
mach-zx
mach-zynq
mm ARM: 9069/1: NOMMU: Fix conversion for_each_membock() to for_each_mem_range() 2021-04-21 13:00:58 +02:00
net
nwfpe
oprofile
plat-omap PM: AVS: smartreflex Move driver to soc specific drivers 2020-10-16 18:28:43 +02:00
plat-orion
plat-pxa
plat-versatile
probes ARM: 9071/1: uprobes: Don't hook on thumb instructions 2021-04-21 13:01:00 +02:00
tools mm/madvise: introduce process_madvise() syscall: an external memory hinting API 2020-10-18 09:27:10 -07:00
vdso kbuild: explicitly specify the build id style 2020-10-09 23:57:30 +09:00
vfp ARM: 9044/1: vfp: use undef hook for VFP support detection 2020-12-30 11:54:02 +01:00
xen Xen/gnttab: handle p2m update errors on a per-slot basis 2021-03-07 12:34:15 +01:00
Kbuild
Kconfig kbuild: Hoist '--orphan-handling' into Kconfig 2020-12-01 22:45:36 +09:00
Kconfig-nommu
Kconfig.assembler
Kconfig.debug ARM: SoC platform updates 2020-10-24 10:33:08 -07:00
Makefile kbuild: Hoist '--orphan-handling' into Kconfig 2020-12-01 22:45:36 +09:00