New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
stm32: unified up_perf initialization #8040
Conversation
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
Why does this PR break my build when enabling CONFIG_SCHED_IRQMONITOR? This looks like a regression from 12.0.0, it used to work and show somewhat true numbers in
For example, nuttx/boards/arm/stm32h7/nucleo-h743zi2/src/stm32_boot.c Lines 53 to 55 in 1f7b49d
#include <arch/board/board.h> which provides STM32_SYSCLK_FREQUENCY macro, visible in this translation unit. Most STM32 boards simply use DWT_CYCCNT (see arch/arm/src/armv7-m/arm_perf.c ) and thus need to know MCU frequency.Does CI check builds for configs with IRQMONITOR, like nucleo-h743zi2:jumbo in arm-12.dat? Yes, it does. arch/arm/src/stm32/stm32_start.c doesn't have this #include, but arch/arm/src/stm32h7/stm32_start.c does, hence no CI build failure.
diff --git a/arch/arm/src/stm32/stm32_start.c b/arch/arm/src/stm32/stm32_start.c
index 08b7d21f0..72332d731 100644
--- a/arch/arm/src/stm32/stm32_start.c
+++ b/arch/arm/src/stm32/stm32_start.c
@@ -29,6 +29,7 @@
#include <debug.h>
#include <nuttx/init.h>
+#include <arch/board/board.h>
#include "arm_internal.h"
#include "nvic.h" |
Already submitted a PR to fix it: #8948 |
Thanks, I guess, will move the discussion there. |
yes, i fixed it |
Summary
move up_perf_init from boards to arch
Impact
Testing