esp_system: startup flow modifications

Changes the startup flow to the ff:

hardware -> core libraries init  -> other libraries init -> os
init (optional) -> app_main

- hardware init resides in the port layer, and is the entry point

- core libraries init executes init functions of core components

- other libraries init executes init functions of other components (weak
references)

- after other lib is init, the app_main function is called, however,

 an OS can wrap the real call to app_main to init its own stuff, and
 *then* call the real app_main
This commit is contained in:
Renz Christian Bagaporo
2020-02-05 22:40:15 +08:00
committed by Angus Gratton
parent 0f43a2620d
commit c53ad56515
8 changed files with 432 additions and 323 deletions

View File

@@ -82,6 +82,11 @@ esp_err_t esp_pthread_set_cfg(const esp_pthread_cfg_t *cfg);
*/
esp_err_t esp_pthread_get_cfg(esp_pthread_cfg_t *p);
/**
* @brief Initialize pthread library
*/
esp_err_t esp_pthread_init(void);
#ifdef __cplusplus
}
#endif