summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--patches/arm-implement-arch_has_kernel_fpu_support-fix.patch42
-rw-r--r--pc/arm-implement-arch_has_kernel_fpu_support-fix.pc1
-rw-r--r--pc/devel-series3
-rw-r--r--txt/arm-implement-arch_has_kernel_fpu_support-fix.txt25
4 files changed, 70 insertions, 1 deletions
diff --git a/patches/arm-implement-arch_has_kernel_fpu_support-fix.patch b/patches/arm-implement-arch_has_kernel_fpu_support-fix.patch
new file mode 100644
index 000000000..462597689
--- /dev/null
+++ b/patches/arm-implement-arch_has_kernel_fpu_support-fix.patch
@@ -0,0 +1,42 @@
+From: Samuel Holland <samuel.holland@sifive.com>
+Subject: ARM: do not select ARCH_HAS_KERNEL_FPU_SUPPORT
+Date: Wed, 8 May 2024 18:37:10 -0700
+
+On 32-bit ARM, conversions between `double` and `long long` require
+runtime library support. Since the kernel does not currently provide this
+library support, the amdgpu driver fails to build:
+
+ ERROR: modpost: "__aeabi_l2d" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined!
+ ERROR: modpost: "__aeabi_d2ulz" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined!
+
+As Arnd reports, there are likely no 32-bit ARM platforms which can use
+the amdgpu driver anyway, due to lack of features like 64-bit prefetchable
+BARs. Since amdgpu is currently the only real user of
+ARCH_HAS_KERNEL_FPU_SUPPORT, drop support for this option instead of
+bothering to implement the library functions.
+
+Link: https://lkml.kernel.org/r/20240509013727.648600-1-samuel.holland@sifive.com
+Fixes: 12624fe2d707 ("ARM: implement ARCH_HAS_KERNEL_FPU_SUPPORT")
+Signed-off-by: Samuel Holland <samuel.holland@sifive.com>
+Reported-by: Thiago Jung Bauermann <thiago.bauermann@linaro.org>
+Closes: https://lore.kernel.org/lkml/87wmp4oo3y.fsf@linaro.org/
+Reported-by: kernel test robot <lkp@intel.com>
+Closes: https://lore.kernel.org/oe-kbuild-all/202404042327.jRpt81kP-lkp@intel.com/
+Suggested-by: Ard Biesheuvel <ardb@kernel.org>
+Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
+---
+
+ arch/arm/Kconfig | 1 -
+ 1 file changed, 1 deletion(-)
+
+--- a/arch/arm/Kconfig~arm-implement-arch_has_kernel_fpu_support-fix
++++ a/arch/arm/Kconfig
+@@ -15,7 +15,6 @@ config ARM
+ select ARCH_HAS_FORTIFY_SOURCE
+ select ARCH_HAS_KEEPINITRD
+ select ARCH_HAS_KCOV
+- select ARCH_HAS_KERNEL_FPU_SUPPORT if KERNEL_MODE_NEON
+ select ARCH_HAS_MEMBARRIER_SYNC_CORE
+ select ARCH_HAS_NON_OVERLAPPING_ADDRESS_SPACE
+ select ARCH_HAS_PTE_SPECIAL if ARM_LPAE
+_
diff --git a/pc/arm-implement-arch_has_kernel_fpu_support-fix.pc b/pc/arm-implement-arch_has_kernel_fpu_support-fix.pc
new file mode 100644
index 000000000..4f40d1661
--- /dev/null
+++ b/pc/arm-implement-arch_has_kernel_fpu_support-fix.pc
@@ -0,0 +1 @@
+arch/arm/Kconfig
diff --git a/pc/devel-series b/pc/devel-series
index 152544d81..5f5edbd05 100644
--- a/pc/devel-series
+++ b/pc/devel-series
@@ -1013,6 +1013,7 @@ kbuild-enable-wcast-function-type-strict-unconditionally.patch
x86-fpu-fix-asm-fpu-typesh-include-guard.patch
arch-add-arch_has_kernel_fpu_support.patch
arm-implement-arch_has_kernel_fpu_support.patch
+arm-implement-arch_has_kernel_fpu_support-fix.patch
arm-crypto-use-cc_flags_fpu-for-neon-cflags.patch
arm64-implement-arch_has_kernel_fpu_support.patch
arm64-crypto-use-cc_flags_fpu-for-neon-cflags.patch
@@ -1022,11 +1023,11 @@ powerpc-implement-arch_has_kernel_fpu_support.patch
x86-implement-arch_has_kernel_fpu_support.patch
riscv-add-support-for-kernel-mode-fpu.patch
drm-amd-display-only-use-hard-float-not-altivec-on-powerpc.patch
-#drm-amd-display-use-arch_has_kernel_fpu_support.patch: https://lkml.kernel.org/r/202404042327.jRpt81kP-lkp@intel.com https://lkml.kernel.org/r/87wmp4oo3y.fsf@linaro.org
drm-amd-display-use-arch_has_kernel_fpu_support.patch
selftests-fpu-move-fp-code-to-a-separate-translation-unit.patch
selftests-fpu-allow-building-on-other-architectures.patch
#
+#
revert-selftests-harness-remove-use-of-line_max.patch
selftests-harness-use-1024-in-place-of-line_max.patch
#
diff --git a/txt/arm-implement-arch_has_kernel_fpu_support-fix.txt b/txt/arm-implement-arch_has_kernel_fpu_support-fix.txt
new file mode 100644
index 000000000..f2f2ea208
--- /dev/null
+++ b/txt/arm-implement-arch_has_kernel_fpu_support-fix.txt
@@ -0,0 +1,25 @@
+From: Samuel Holland <samuel.holland@sifive.com>
+Subject: ARM: do not select ARCH_HAS_KERNEL_FPU_SUPPORT
+Date: Wed, 8 May 2024 18:37:10 -0700
+
+On 32-bit ARM, conversions between `double` and `long long` require
+runtime library support. Since the kernel does not currently provide this
+library support, the amdgpu driver fails to build:
+
+ ERROR: modpost: "__aeabi_l2d" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined!
+ ERROR: modpost: "__aeabi_d2ulz" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined!
+
+As Arnd reports, there are likely no 32-bit ARM platforms which can use
+the amdgpu driver anyway, due to lack of features like 64-bit prefetchable
+BARs. Since amdgpu is currently the only real user of
+ARCH_HAS_KERNEL_FPU_SUPPORT, drop support for this option instead of
+bothering to implement the library functions.
+
+Link: https://lkml.kernel.org/r/20240509013727.648600-1-samuel.holland@sifive.com
+Fixes: 12624fe2d707 ("ARM: implement ARCH_HAS_KERNEL_FPU_SUPPORT")
+Signed-off-by: Samuel Holland <samuel.holland@sifive.com>
+Reported-by: Thiago Jung Bauermann <thiago.bauermann@linaro.org>
+Closes: https://lore.kernel.org/lkml/87wmp4oo3y.fsf@linaro.org/
+Reported-by: kernel test robot <lkp@intel.com>
+Closes: https://lore.kernel.org/oe-kbuild-all/202404042327.jRpt81kP-lkp@intel.com/
+Suggested-by: Ard Biesheuvel <ardb@kernel.org>