From c0aa4d27d3f2767e88c6c8c4634425086156f7f5 Mon Sep 17 00:00:00 2001 From: Ben Wolsieffer Date: Sat, 30 Dec 2023 15:45:44 -0500 Subject: [PATCH] [nrf fromtree] soc: nrf53: fix building anomaly 168 workaround With GCC 12.3 and binutils 2.40, the build fails with: <...>/zephyr/arch/arm/core/cortex_m/cpu_idle.S: Assembler messages: <...>/zephyr/arch/arm/core/cortex_m/cpu_idle.S:51: Error: junk at end of line, first unrecognized character is `n' <...>/zephyr/arch/arm/core/cortex_m/cpu_idle.S:133: Info: macro invoked from here Because the SOC_ON_EXIT_CPU_IDLE macro puts all the statements on a single line, there must be a semicolon after .rept Signed-off-by: Ben Wolsieffer (cherry picked from commit 37352d3d2993f02b26b027b1a3bde11ab2254319) --- soc/arm/nordic_nrf/nrf53/soc_cpu_idle.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/soc/arm/nordic_nrf/nrf53/soc_cpu_idle.h b/soc/arm/nordic_nrf/nrf53/soc_cpu_idle.h index dcb0c73d068..c02c9451419 100644 --- a/soc/arm/nordic_nrf/nrf53/soc_cpu_idle.h +++ b/soc/arm/nordic_nrf/nrf53/soc_cpu_idle.h @@ -13,12 +13,12 @@ #if defined(CONFIG_SOC_NRF53_ANOMALY_168_WORKAROUND_FOR_EXECUTION_FROM_RAM) #define SOC_ON_EXIT_CPU_IDLE \ - .rept 26 \ + .rept 26; \ nop; \ .endr #elif defined(CONFIG_SOC_NRF53_ANOMALY_168_WORKAROUND) #define SOC_ON_EXIT_CPU_IDLE \ - .rept 8 \ + .rept 8; \ nop; \ .endr #endif