feat(hw_support): move call_start_cpu0 into flash to save IRAM

This commit is contained in:
Michael (XIAO Xufeng)
2025-05-13 18:56:18 +08:00
parent 2fb938c7c3
commit 7549d083a4
2 changed files with 176 additions and 74 deletions

View File

@@ -200,11 +200,17 @@ static void do_secondary_init(void)
static void start_cpu0_default(void)
{
// Initialize core components and services.
// Operations that needs the cache to be disabled have to be done here.
do_core_init();
// Execute constructors.
do_global_ctors();
/* ----------------------------------Separator-----------------------------
* After this stage, other CPU start running with the cache, however the scheduler (and ipc service) is not available.
* Don't touch the cache/MMU until the OS is up.
*/
// Execute init functions of other components; blocks
// until all cores finish (when !CONFIG_ESP_SYSTEM_SINGLE_CORE_MODE).
do_secondary_init();