Browse Source

cleanup FPU support for ARM targets.

Waldemar Brodkorb 9 years ago
parent
commit
4f93b213f2

+ 1 - 0
Config.in

@@ -35,6 +35,7 @@ source "target/config/Config.in.qemuopts"
 source "target/config/Config.in.kernelversion"
 source "target/config/Config.in.libc"
 source "target/config/Config.in.abi"
+source "target/config/Config.in.fpu"
 source "target/config/Config.in.float"
 source "target/config/Config.in.binfmt"
 source "target/config/Config.in.target"

+ 0 - 3
target/arm/kernel/qemu-arm-vexpress-a9

@@ -9,8 +9,5 @@ CONFIG_ARCH_VEXPRESS_TC2_PM=y
 CONFIG_KUSER_HELPERS=y
 CONFIG_ARM_AMBA=y
 CONFIG_ATAGS=y
-CONFIG_VFP=y
-CONFIG_VFPv3=y
-CONFIG_NEON=y
 CONFIG_SERIAL_AMBA_PL011=y
 CONFIG_SERIAL_AMBA_PL011_CONSOLE=y

+ 0 - 1
target/arm/kernel/raspberry-pi

@@ -3,7 +3,6 @@ CONFIG_FIQ=y
 CONFIG_ARM_PATCH_PHYS_VIRT=y
 CONFIG_KUSER_HELPERS=y
 CONFIG_ARCH_MULTI_V6=y
-CONFIG_VFP=y
 CONFIG_ARCH_BCM2708=y
 CONFIG_ARCH_BCM2835=y
 CONFIG_MACH_BCM2708=y

+ 0 - 2
target/arm/kernel/raspberry-pi2

@@ -6,8 +6,6 @@ CONFIG_ARCH_BCM2836=y
 CONFIG_MACH_BCM2709=y
 CONFIG_HAVE_ARM_ARCH_TIMER=y
 CONFIG_FIQ=y
-CONFIG_VFP=y
-CONFIG_NEON=y
 CONFIG_SERIAL_AMBA_PL011=y
 CONFIG_SERIAL_AMBA_PL011_CONSOLE=y
 CONFIG_CMDLINE_EXTEND=y

+ 0 - 4
target/arm/kernel/solidrun-imx6

@@ -8,10 +8,6 @@ CONFIG_SOC_IMX6SL=y
 CONFIG_LOCAL_TIMERS=y
 CONFIG_MXC_DEBUG_BOARD=y
 CONFIG_KUSER_HELPERS=y
-CONFIG_VFP=y
-CONFIG_VFPv3=y
-CONFIG_NEON=y
-CONFIG_KERNEL_MODE_NEON=y
 CONFIG_PCI_IMX6=y
 CONFIG_SERIAL_IMX=y
 CONFIG_SERIAL_IMX_CONSOLE=y

+ 2 - 2
target/arm/systems/raspberry-pi

@@ -2,11 +2,11 @@ config ADK_TARGET_SYSTEM_RASPBERRY_PI
 	bool "Raspberry PI"
 	select ADK_arm
 	select ADK_little
-	select ADK_fpu_vfp
 	select ADK_raspberry_pi
 	select ADK_CPU_ARM1176JZF_S
-	select ADK_TARGET_BOARD_BCM28XX
 	select ADK_TARGET_CPU_WITH_FPU
+	select ADK_TARGET_CPU_WITH_FPU_VFP
+	select ADK_TARGET_BOARD_BCM28XX
 	select ADK_TARGET_WITH_VGA
 	select ADK_TARGET_WITH_SERIAL
 	select ADK_TARGET_WITH_CPU_FREQ

+ 1 - 1
target/arm/systems/raspberry-pi2

@@ -2,11 +2,11 @@ config ADK_TARGET_SYSTEM_RASPBERRY_PI2
 	bool "Raspberry PI 2"
 	select ADK_arm
 	select ADK_little
-	select ADK_fpu_vfp
 	select ADK_raspberry_pi2
 	select ADK_CPU_CORTEX_A7
 	select ADK_TARGET_BOARD_BCM28XX
 	select ADK_TARGET_CPU_WITH_FPU
+	select ADK_TARGET_CPU_WITH_FPU_NEON
 	select ADK_TARGET_WITH_VGA
 	select ADK_TARGET_WITH_SERIAL
 	select ADK_TARGET_WITH_CPU_FREQ

+ 1 - 1
target/arm/systems/solidrun-imx6

@@ -2,10 +2,10 @@ config ADK_TARGET_SYSTEM_SOLIDRUN_IMX6
 	bool "Solidrun IMX6 Embedded Systems"
 	select ADK_arm
 	select ADK_little
-	select ADK_fpu_neon
 	select ADK_solidrun_imx6
 	select ADK_CPU_CORTEX_A9
 	select ADK_TARGET_CPU_WITH_FPU
+	select ADK_TARGET_CPU_WITH_FPU_NEON
 	select ADK_TARGET_WITH_VGA
 	select ADK_TARGET_WITH_SERIAL
 	select ADK_TARGET_WITH_CPU_FREQ

+ 0 - 11
target/config/Config.in.arm.default

@@ -1,14 +1,3 @@
 # This file is part of the OpenADK project. OpenADK is copyrighted
 # material, please see the LICENCE file in the top-level directory.
 
-config ADK_fpu_neon
-	bool
-
-config ADK_fpu_vfp
-	bool
-
-config ADK_TARGET_FPU
-	string
-	default "vfp" if ADK_fpu_vfp
-	default "neon" if ADK_fpu_neon
-

+ 16 - 0
target/config/Config.in.cpu

@@ -4,6 +4,22 @@
 config ADK_TARGET_CPU_WITH_FPU
 	bool
 
+config ADK_TARGET_CPU_WITH_FPU_VFP
+	bool
+	select ADK_fpu_vfp
+
+config ADK_TARGET_CPU_WITH_FPU_VFP3
+	bool
+	select ADK_fpu_vfp3
+
+config ADK_TARGET_CPU_WITH_FPU_VFP4
+	bool
+	select ADK_fpu_vfp4
+
+config ADK_TARGET_CPU_WITH_FPU_NEON
+	bool
+	select ADK_fpu_neon
+
 config ADK_TARGET_CPU_WITH_VT
 	bool
 

+ 5 - 0
target/config/Config.in.fpu

@@ -0,0 +1,5 @@
+# This file is part of the OpenADK project. OpenADK is copyrighted
+# material, please see the LICENCE file in the top-level directory.
+
+source target/config/Config.in.fpu.choice
+source target/config/Config.in.fpu.default

+ 3 - 0
target/config/Config.in.fpu.choice

@@ -0,0 +1,3 @@
+# This file is part of the OpenADK project. OpenADK is copyrighted
+# material, please see the LICENCE file in the top-level directory.
+

+ 23 - 0
target/config/Config.in.fpu.default

@@ -0,0 +1,23 @@
+# This file is part of the OpenADK project. OpenADK is copyrighted
+# material, please see the LICENCE file in the top-level directory.
+
+config ADK_fpu_neon
+	bool
+
+config ADK_fpu_vfp
+	bool
+
+config ADK_fpu_vfp3
+	bool
+
+config ADK_fpu_vfp4
+	bool
+
+config ADK_TARGET_FPU
+	string
+	depends on ADK_TARGET_ARCH_ARM
+	default "vfp" if ADK_fpu_vfp
+	default "vfp3" if ADK_fpu_vfp3
+	default "vfp4" if ADK_fpu_vfp4
+	default "neon" if ADK_fpu_neon
+

+ 1 - 0
target/config/Config.in.qemu

@@ -36,6 +36,7 @@ config ADK_TARGET_QEMU_ARM_MODEL_VEXPRESS_A9
 	bool "ARM Ltd. Versatile Express with Cortex-A9"
 	select ADK_CPU_CORTEX_A9
 	select ADK_TARGET_CPU_WITH_FPU
+	select ADK_TARGET_CPU_WITH_FPU_NEON
 
 config ADK_TARGET_QEMU_ARM_MODEL_STELLARIS_M3
 	bool "Stellaris LM3S6965EVB with Cortex-M3"

+ 16 - 0
target/linux/config/Config.in.kernel

@@ -173,6 +173,22 @@ menu "Kernel options"
 config ADK_KERNEL_MMU
 	bool
 
+config ADK_KERNEL_VFP
+	bool
+	default y if ADK_TARGET_CPU_WITH_FPU_VFP
+
+config ADK_KERNEL_VFPv3
+	bool
+	default y if ADK_TARGET_CPU_WITH_FPU_VFP3
+
+config ADK_KERNEL_NEON
+	bool
+	default y if ADK_TARGET_CPU_WITH_FPU_NEON
+
+config ADK_KERNEL_MODE_NEON
+	bool
+	default y if ADK_TARGET_CPU_WITH_FPU_NEON
+
 config ADK_TARGET_NO_CMDLINE
 	bool "Do not builtin any kernel cmdline"
 	help

+ 2 - 0
toolchain/gcc/Makefile

@@ -86,8 +86,10 @@ endif
 #
 
 ifneq ($(ADK_TARGET_ARCH_ARM)$(ADK_TARGET_ARCH_MIPS)$(ADK_TARGET_ARCH_PPC),)
+ifneq ($(ADK_TARGET_FLOAT),)
 GCC_CONFOPTS+=		--with-float=$(ADK_TARGET_FLOAT)
 endif
+endif
 
 ifeq ($(ADK_TARGET_ARCH_M68K)$(ADK_TARGET_ARCH_SH)$(ADK_TARGET_ARCH_X86_64)$(ADK_TARGET_ARCH_X86),)
 GCC_FINAL_CONFOPTS+=	--disable-biarch --disable-multilib