You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2023/01/06 02:51:26 UTC

[GitHub] [nuttx] Gary-Hobson opened a new pull request, #8040: stm32: unified up_perf initialization

Gary-Hobson opened a new pull request, #8040:
URL: https://github.com/apache/nuttx/pull/8040

   ## Summary
   move up_perf_init from boards to arch
   
   ## Impact
   
   ## Testing
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [nuttx] ALTracer commented on pull request #8040: stm32: unified up_perf initialization

Posted by "ALTracer (via GitHub)" <gi...@apache.org>.
ALTracer commented on PR #8040:
URL: https://github.com/apache/nuttx/pull/8040#issuecomment-1493664103

   Thanks, I guess, will move the discussion there.
   _Why is my text in your quote suddenly Chinese? I don't speak it... Auto translation maybe?_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [nuttx] xiaoxiang781216 merged pull request #8040: stm32: unified up_perf initialization

Posted by GitBox <gi...@apache.org>.
xiaoxiang781216 merged PR #8040:
URL: https://github.com/apache/nuttx/pull/8040


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [nuttx] Gary-Hobson commented on pull request #8040: stm32: unified up_perf initialization

Posted by "Gary-Hobson (via GitHub)" <gi...@apache.org>.
Gary-Hobson commented on PR #8040:
URL: https://github.com/apache/nuttx/pull/8040#issuecomment-1493658348

   > 为什么这个 PR 在启用CONFIG_SCHED_IRQMONITOR时会破坏我的构建?这看起来像是从 12.0.0 回归的,它曾经工作并在 中显示一些真实的数字。我正在为修改后的配置构建stm32f411-minimum。`ps`
   > 
   > ```
   > chip/stm32_start.c: In function '__start':
   > chip/stm32_start.c:161:24: error: 'STM32_SYSCLK_FREQUENCY' undeclared (first use in this function)
   >   161 |   up_perf_init((void *)STM32_SYSCLK_FREQUENCY);
   >       |                        ^~~~~~~~~~~~~~~~~~~~~~
   > chip/stm32_start.c:161:24: note: each undeclared identifier is reported only once for each function it appears in
   > make[1]: *** [Makefile:157: stm32_start.o] Error 1
   > ```
   > 
   > 例如
   > 
   > https://github.com/apache/nuttx/blob/1f7b49d7003c9bf27ade13be6fcd177b4352299d/boards/arm/stm32h7/nucleo-h743zi2/src/stm32_boot.c#L53-L55
   > 
   > 提供了STM32_SYSCLK_FREQUENCY宏,在此翻译单元中可见。大多数STM32板只是使用(参见),因此需要知道MCU频率。
   > _CI 是否使用 IRQMONITOR 检查配置的构建,例如 arm-743.dat 中的 nucleo-h2zi12:jumbo?是的,确实如此。_
   > 没有此#include,但确实如此,因此没有 CI 构建失败。`#include <arch/board/board.h>``DWT_CYCCNT``arch/arm/src/armv7-m/arm_perf.c``arch/arm/src/stm32/stm32_start.c``arch/arm/src/stm32h7/stm32_start.c`
   > ```diff
   > 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: https://github.com/apache/nuttx/pull/8948


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [nuttx] Gary-Hobson commented on pull request #8040: stm32: unified up_perf initialization

Posted by "Gary-Hobson (via GitHub)" <gi...@apache.org>.
Gary-Hobson commented on PR #8040:
URL: https://github.com/apache/nuttx/pull/8040#issuecomment-1493692537

   > Thanks, I guess, will move the discussion there. _Why is my text in your quote suddenly Chinese? I don't speak it... Auto translation maybe?_
   
   yes, i fixed it


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [nuttx] ALTracer commented on pull request #8040: stm32: unified up_perf initialization

Posted by "ALTracer (via GitHub)" <gi...@apache.org>.
ALTracer commented on PR #8040:
URL: https://github.com/apache/nuttx/pull/8040#issuecomment-1493500471

   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 `ps`. I was building for stm32f411-minimum with modified config.
   ```
   chip/stm32_start.c: In function '__start':
   chip/stm32_start.c:161:24: error: 'STM32_SYSCLK_FREQUENCY' undeclared (first use in this function)
     161 |   up_perf_init((void *)STM32_SYSCLK_FREQUENCY);
         |                        ^~~~~~~~~~~~~~~~~~~~~~
   chip/stm32_start.c:161:24: note: each undeclared identifier is reported only once for each function it appears in
   make[1]: *** [Makefile:157: stm32_start.o] Error 1
   ```
   For example,
   https://github.com/apache/nuttx/blob/1f7b49d7003c9bf27ade13be6fcd177b4352299d/boards/arm/stm32h7/nucleo-h743zi2/src/stm32_boot.c#L53-L55 had `#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.
   ```patch
   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"
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org