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 2020/11/03 13:40:16 UTC

[GitHub] [incubator-nuttx] fjpanag commented on pull request #2177: FLASH waiting cycles are configured based on HCLK.

fjpanag commented on pull request #2177:
URL: https://github.com/apache/incubator-nuttx/pull/2177#issuecomment-720600015


   Hi @v01d ,
   
   I wasn't aware of this, I thought that these functions were only used by the start-up code.
   
   So, let me present some points. Let's think how we can make this better.
   
   - I did a search on were `stm32_clockenable()` is used. It is true that it is called only from start-up code. No other code in STM32 arch is using it. The only other use of this function is in `stm3210e-eval/src/stm32_idle.c`, which is a board-level function. Maybe this specific board is to be fixed?
   
   - I think clock configuration needs different routines for the start-up code, and for dynamically changing frequency. Starting the system usually makes many assumptions for its state (that do not apply during run-time). Also, usually, some of the initial configuration is not  required to be repeated later.
   
   - Based on the assumption that `stm32_stdclockconfig()` is called outside `stm32_start()`, then core-overdrive is also broken on STM32F4 targets, I think. It has similar requirements.
   
   - If we want to make this perfect (and take the most performance available from these chips), then there should also be a way to state the voltage range that the MCU works. Maybe in `board.h`?
   
   - Having multiple `*_rcc.c` files is very very annoying when maintaining code. Maybe we should first try to merge all these files in one?
   


----------------------------------------------------------------
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.

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