From c1afb28a7280da16a88c69e9aba316b3e3484f30 Mon Sep 17 00:00:00 2001 From: Kai Vehmanen Date: Wed, 9 Oct 2024 17:22:02 +0300 Subject: [PATCH] zephyr: move to strict headers builds for all targets Remove CONFIG_SOF_ZEPHYR_STRICT_HEADERS and make strict headers mode the only supported way to build SOF with Zephyr. This means SOF Zephyr builds do not use any headers from sof/xtos/include anymore. This change simplifies the SOF build as full RTOS adaptation is in sof/zephyr/include for Zephyr builds. Link: https://github.com/thesofproject/sof/issues/9015 Signed-off-by: Kai Vehmanen --- smex/CMakeLists.txt | 2 -- zephyr/CMakeLists.txt | 10 +--------- zephyr/Kconfig | 10 ---------- 3 files changed, 1 insertion(+), 21 deletions(-) diff --git a/smex/CMakeLists.txt b/smex/CMakeLists.txt index d5a9824e2c0d..01d9bf8778b3 100644 --- a/smex/CMakeLists.txt +++ b/smex/CMakeLists.txt @@ -32,8 +32,6 @@ target_include_directories(smex PRIVATE ) # TODO: smex should not need RTOS headers: FIX. -if (NOT CONFIG_SOF_ZEPHYR_STRICT_HEADERS) target_include_directories(smex PRIVATE "${SOF_ROOT_SOURCE_DIRECTORY}/xtos/include" ) -endif() diff --git a/zephyr/CMakeLists.txt b/zephyr/CMakeLists.txt index 9a84d044ffaa..3527d29ef1ba 100644 --- a/zephyr/CMakeLists.txt +++ b/zephyr/CMakeLists.txt @@ -158,15 +158,7 @@ target_include_directories(SOF INTERFACE ${RIMAGE_TOP}/src/include) target_include_directories(SOF INTERFACE ${SOF_SRC_PATH}/include) target_include_directories(SOF INTERFACE ${SOF_SRC_PATH}/arch/${ARCH}/include) target_include_directories(SOF INTERFACE ${sof_top_dir}/third_party/include) - -# TODO: Zephyr should not need xtos headers: FIX. -if (CONFIG_SOF_ZEPHYR_STRICT_HEADERS) - target_include_directories(SOF INTERFACE ${sof_top_dir}/zephyr/include) -else() - # include Zephyr before xtos to flag up any errors in SOF - target_include_directories(SOF INTERFACE ${sof_top_dir}/zephyr/include) - target_include_directories(SOF INTERFACE ${sof_top_dir}/${PLATFORM_HEADERS}/include) -endif() +target_include_directories(SOF INTERFACE ${sof_top_dir}/zephyr/include) # SOF module init zephyr_library_named(modules_sof) diff --git a/zephyr/Kconfig b/zephyr/Kconfig index b8915b69d8ee..b348fd7b9728 100644 --- a/zephyr/Kconfig +++ b/zephyr/Kconfig @@ -18,16 +18,6 @@ config ZEPHYR_NATIVE_DRIVERS dai-zephyr will be used instead of legacy xtos version. -config SOF_ZEPHYR_STRICT_HEADERS - bool "Experimental: Force build with Zephyr RTOS headers only" - default n - help - This is a transitional option that allows developers to test builds - only using the Zephyr RTOS headers. This will eventually become the - default header configuration when native Zephyr is ready and this menu - choice will be removed. - If unsure, say n. - config DMA_DOMAIN bool "Enable the usage of DMA domain." default y if IMX8M