mirror of
https://github.com/espressif/ESP8266_RTOS_SDK.git
synced 2025-05-22 17:47:04 +08:00
feat(freertos): Link FreeRTOS idle task and its hook function to IRAM
This commit is contained in:
@ -75,12 +75,12 @@ static uint32_t task_ms_to_tick_wrapper(uint32_t ms)
|
||||
return (uint32_t)(ms / portTICK_RATE_MS);
|
||||
}
|
||||
|
||||
static void task_suspend_all_wrapper(void)
|
||||
static void IRAM_ATTR task_suspend_all_wrapper(void)
|
||||
{
|
||||
vTaskSuspendAll();
|
||||
}
|
||||
|
||||
static void task_resume_all_wrapper(void)
|
||||
static void IRAM_ATTR task_resume_all_wrapper(void)
|
||||
{
|
||||
xTaskResumeAll();
|
||||
}
|
||||
|
@ -14,6 +14,7 @@
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#include "esp_attr.h"
|
||||
#include "esp_log.h"
|
||||
#include "esp_libc.h"
|
||||
#include "esp_wifi_osi.h"
|
||||
@ -78,7 +79,7 @@ esp_err_t esp_task_wdt_init(void)
|
||||
* @brief Reset(Feed) the Task Watchdog Timer (TWDT) on behalf of the currently
|
||||
* running task
|
||||
*/
|
||||
void esp_task_wdt_reset(void)
|
||||
void IRAM_ATTR esp_task_wdt_reset(void)
|
||||
{
|
||||
WDT_FEED();
|
||||
}
|
||||
|
@ -2054,7 +2054,7 @@ void vTaskEndScheduler( void )
|
||||
}
|
||||
/*----------------------------------------------------------*/
|
||||
|
||||
void vTaskSuspendAll( void )
|
||||
void IRAM_ATTR vTaskSuspendAll( void )
|
||||
{
|
||||
/* A critical section is not required as the variable is of type
|
||||
BaseType_t. Please read Richard Barry's reply in the following link to a
|
||||
@ -2127,7 +2127,7 @@ void vTaskSuspendAll( void )
|
||||
#endif /* configUSE_TICKLESS_IDLE */
|
||||
/*----------------------------------------------------------*/
|
||||
|
||||
BaseType_t xTaskResumeAll( void )
|
||||
BaseType_t IRAM_ATTR xTaskResumeAll( void )
|
||||
{
|
||||
TCB_t *pxTCB = NULL;
|
||||
BaseType_t xAlreadyYielded = pdFALSE;
|
||||
@ -2611,7 +2611,7 @@ implementations require configUSE_TICKLESS_IDLE to be set to a value other than
|
||||
#endif /* INCLUDE_xTaskAbortDelay */
|
||||
/*----------------------------------------------------------*/
|
||||
|
||||
BaseType_t xTaskIncrementTick( void )
|
||||
BaseType_t IRAM_ATTR xTaskIncrementTick( void )
|
||||
{
|
||||
TCB_t * pxTCB;
|
||||
TickType_t xItemValue;
|
||||
|
@ -151,7 +151,7 @@ void PortEnableInt_NoNest( void );
|
||||
not necessary for to use this port. They are defined so the common demo files
|
||||
(which build with all the ports) will build. */
|
||||
#define portTASK_FUNCTION_PROTO( vFunction, pvParameters ) void vFunction( void *pvParameters )
|
||||
#define portTASK_FUNCTION( vFunction, pvParameters ) void vFunction( void *pvParameters )
|
||||
#define portTASK_FUNCTION( vFunction, pvParameters ) void IRAM_ATTR vFunction( void *pvParameters )
|
||||
/*-----------------------------------------------------------*/
|
||||
|
||||
void _xt_user_exit (void);
|
||||
|
@ -344,7 +344,7 @@ BaseType_t xQueueGenericReceive(QueueHandle_t xQueue, void * const pvBuffer,
|
||||
return xQueueReceive(xQueue, pvBuffer, xTicksToWait);
|
||||
}
|
||||
|
||||
void vApplicationIdleHook(void)
|
||||
void IRAM_ATTR vApplicationIdleHook(void)
|
||||
{
|
||||
extern void pmIdleHook(void);
|
||||
extern void esp_task_wdt_reset(void);
|
||||
|
Reference in New Issue
Block a user