kopia lustrzana https://github.com/espressif/esp-idf
startup: moved init core functions out of iram memory
rodzic
d59e8b50d2
commit
a1e5dd58b2
|
@ -5,6 +5,12 @@ entries:
|
||||||
panic_handler (noflash)
|
panic_handler (noflash)
|
||||||
reset_reason (noflash)
|
reset_reason (noflash)
|
||||||
system_api:esp_system_abort (noflash)
|
system_api:esp_system_abort (noflash)
|
||||||
|
startup:do_secondary_init(default)
|
||||||
|
startup:start_cpu0_default(default)
|
||||||
|
startup:do_core_init(default)
|
||||||
|
startup:do_system_init_fn(default)
|
||||||
|
startup:start_cpu_other_cores_default(default)
|
||||||
|
startup:do_global_ctors(default)
|
||||||
|
|
||||||
if ESP_CONSOLE_USB_CDC_SUPPORT_ETS_PRINTF:
|
if ESP_CONSOLE_USB_CDC_SUPPORT_ETS_PRINTF:
|
||||||
usb_console:esp_usb_console_write_char (noflash)
|
usb_console:esp_usb_console_write_char (noflash)
|
||||||
|
|
|
@ -120,7 +120,7 @@ static IRAM_ATTR void _Unwind_SetNoFunctionContextInstall_Default(unsigned char
|
||||||
|
|
||||||
static const char* TAG = "cpu_start";
|
static const char* TAG = "cpu_start";
|
||||||
|
|
||||||
static void IRAM_ATTR do_global_ctors(void)
|
static void do_global_ctors(void)
|
||||||
{
|
{
|
||||||
extern void (*__init_array_start)(void);
|
extern void (*__init_array_start)(void);
|
||||||
extern void (*__init_array_end)(void);
|
extern void (*__init_array_end)(void);
|
||||||
|
@ -140,7 +140,7 @@ static void IRAM_ATTR do_global_ctors(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void IRAM_ATTR do_system_init_fn(void)
|
static void do_system_init_fn(void)
|
||||||
{
|
{
|
||||||
extern esp_system_init_fn_t _esp_system_init_fn_array_start;
|
extern esp_system_init_fn_t _esp_system_init_fn_array_start;
|
||||||
extern esp_system_init_fn_t _esp_system_init_fn_array_end;
|
extern esp_system_init_fn_t _esp_system_init_fn_array_end;
|
||||||
|
@ -166,7 +166,7 @@ static void IRAM_ATTR start_app_other_cores_default(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void IRAM_ATTR start_cpu_other_cores_default(void)
|
static void start_cpu_other_cores_default(void)
|
||||||
{
|
{
|
||||||
do_system_init_fn();
|
do_system_init_fn();
|
||||||
|
|
||||||
|
@ -178,7 +178,7 @@ static void IRAM_ATTR start_cpu_other_cores_default(void)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static void IRAM_ATTR do_core_init(void)
|
static void do_core_init(void)
|
||||||
{
|
{
|
||||||
/* Initialize heap allocator. WARNING: This *needs* to happen *after* the app cpu has booted.
|
/* Initialize heap allocator. WARNING: This *needs* to happen *after* the app cpu has booted.
|
||||||
If the heap allocator is initialized first, it will put free memory linked list items into
|
If the heap allocator is initialized first, it will put free memory linked list items into
|
||||||
|
@ -277,7 +277,7 @@ static void IRAM_ATTR do_core_init(void)
|
||||||
assert(flash_ret == ESP_OK);
|
assert(flash_ret == ESP_OK);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void IRAM_ATTR do_secondary_init(void)
|
static void do_secondary_init(void)
|
||||||
{
|
{
|
||||||
#if !CONFIG_ESP_SYSTEM_SINGLE_CORE_MODE
|
#if !CONFIG_ESP_SYSTEM_SINGLE_CORE_MODE
|
||||||
// The port layer transferred control to this function with other cores 'paused',
|
// The port layer transferred control to this function with other cores 'paused',
|
||||||
|
@ -304,7 +304,7 @@ static void IRAM_ATTR do_secondary_init(void)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void IRAM_ATTR start_cpu0_default(void)
|
void start_cpu0_default(void)
|
||||||
{
|
{
|
||||||
|
|
||||||
ESP_EARLY_LOGI(TAG, "Pro cpu start user code");
|
ESP_EARLY_LOGI(TAG, "Pro cpu start user code");
|
||||||
|
|
|
@ -113,5 +113,6 @@ entries:
|
||||||
queue: xQueueRemoveFromSet (default)
|
queue: xQueueRemoveFromSet (default)
|
||||||
queue: xQueueSelectFromSet (default)
|
queue: xQueueSelectFromSet (default)
|
||||||
port:start_app(default)
|
port:start_app(default)
|
||||||
|
port:main_task(default)
|
||||||
port:start_app_other_cores(default)
|
port:start_app_other_cores(default)
|
||||||
|
port:xPortStartScheduler(default)
|
Ładowanie…
Reference in New Issue