summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Hasemeyer <markhas@google.com>2022-11-21 15:18:01 -0700
committerChromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com>2022-11-29 18:29:52 +0000
commitb31068ff225f5e61460a4bd09c406327b91f1443 (patch)
treeaba7af498aae761e551493da1e4d240730cd05e3
parent1350988ef5d4b75366c8bd0bd54bfb7bf041c600 (diff)
downloadchrome-ec-b31068ff225f5e61460a4bd09c406327b91f1443.tar.gz
zephyr: Remove CONFIG_PLATFORM_EC_FPU
Remove CONFIG_PLATFORM_EC_FPU. Use Zephyr's CONFIG_FPU option instead. BUG=b:217926701 BRANCH=none TEST=twister -T zephyr/test/ TEST=zmake compare-builds -a Signed-off-by: Mark Hasemeyer <markhas@google.com> Change-Id: Icd0fdbc440f0dd574b75bf5ca0f1750f1e858b40 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/4049382 Code-Coverage: Zoss <zoss-cl-coverage@prod.google.com> Reviewed-by: Keith Short <keithshort@chromium.org>
-rw-r--r--util/config_allowed.txt1
-rw-r--r--zephyr/Kconfig10
-rw-r--r--zephyr/shim/include/fpu.h4
3 files changed, 3 insertions, 12 deletions
diff --git a/util/config_allowed.txt b/util/config_allowed.txt
index 033439a022..f7e20b379c 100644
--- a/util/config_allowed.txt
+++ b/util/config_allowed.txt
@@ -407,6 +407,7 @@ CONFIG_FLASH_WRITE_SIZE
CONFIG_FMAP
CONFIG_FOO
CONFIG_FORCE_CONSOLE_RESUME
+CONFIG_FPU
CONFIG_FPU_WARNINGS
CONFIG_FP_SENSOR_ELAN515
CONFIG_FP_SENSOR_ELAN80
diff --git a/zephyr/Kconfig b/zephyr/Kconfig
index 9e04f4a679..6b0a512328 100644
--- a/zephyr/Kconfig
+++ b/zephyr/Kconfig
@@ -349,16 +349,6 @@ config PLATFORM_EC_FLASH_CROS
e.g. to support auto-update. Various write-protection features are
also provided.
-config PLATFORM_EC_FPU
- bool "Support floating point"
- depends on FPU && (CPU_CORTEX_M || RISCV) && !NEWLIB_LIBC
- default y
- help
- This enables support for floating point. This is generally already
- provided in Zephyr, but the EC side expects a few functions to be
- available which are not available with Zephyr's minimal lib: sqrtf()
- and fabsf(). Enabling this options defines them.
-
config PLATFORM_EC_HOOKS
bool "Hooks and deferred compatibility shim"
default y
diff --git a/zephyr/shim/include/fpu.h b/zephyr/shim/include/fpu.h
index 02e6a7c5f4..20df108b87 100644
--- a/zephyr/shim/include/fpu.h
+++ b/zephyr/shim/include/fpu.h
@@ -16,7 +16,7 @@
* This code is taken from core/cortex-m/include/fpu.h
*/
-#ifdef CONFIG_PLATFORM_EC_FPU
+#ifdef CONFIG_FPU
/* Implementation for Cortex-M */
#ifdef CONFIG_CPU_CORTEX_M
@@ -61,6 +61,6 @@ static inline float fabsf(float v)
#error "Unsupported core: please add an implementation"
#endif
-#endif /* CONFIG_PLATFORM_EC_FPU */
+#endif /* CONFIG_FPU */
#endif /* __CROS_EC_MATH_H */