diff --git a/src/arch/xtensa/include/xtensa/config/core.h b/src/arch/xtensa/include/xtensa/config/core.h index 4cf7606df707..aa18c42a947d 100644 --- a/src/arch/xtensa/include/xtensa/config/core.h +++ b/src/arch/xtensa/include/xtensa/config/core.h @@ -36,22 +36,16 @@ #ifndef XTENSA_CONFIG_CORE_H #define XTENSA_CONFIG_CORE_H -/* - * This define is used by the new 2023 xt-clang toolchain and, while there are a few definitions - * (identical to this one) in various implementations such as newlib, none of them is in use when - * building SOF with Zephyr and XtensaTools. +/* xt-clang uses UINT32_C() without import it. This affects both Zephyr and XTOS. + * See #9413 for the longer story. */ - -#if defined(__ZEPHYR__) - -#ifndef __UINT32_C -#define __UINT32_C(x) x ## U -#endif - -#ifndef UINT32_C -#define UINT32_C(x) __UINT32_C(x) -#endif - +#if defined(_ASMLANGUAGE) || defined(__ASSEMBLER__) +# ifndef UINT32_C +# define UINT32_C(x) x +# endif +#else + /* UINT32_C(x) x ## U */ +# include #endif /* CONFIGURATION INDEPENDENT DEFINITIONS: */