mirror of
https://github.com/espressif/ESP8266_RTOS_SDK.git
synced 2025-05-23 01:58:24 +08:00
fix(esp8266): Link critical function to IRAM
NMI calling function contains of "enter/exit critical"
This commit is contained in:
@ -16,6 +16,7 @@
|
|||||||
|
|
||||||
#include "esp_libc.h"
|
#include "esp_libc.h"
|
||||||
#include "esp_system.h"
|
#include "esp_system.h"
|
||||||
|
#include "esp_attr.h"
|
||||||
#include "esp_wifi_os_adapter.h"
|
#include "esp_wifi_os_adapter.h"
|
||||||
|
|
||||||
#include "freertos/FreeRTOS.h"
|
#include "freertos/FreeRTOS.h"
|
||||||
@ -30,14 +31,14 @@
|
|||||||
#include "esp_newlib.h"
|
#include "esp_newlib.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static uint32_t enter_critical_wrapper(void)
|
static uint32_t IRAM_ATTR enter_critical_wrapper(void)
|
||||||
{
|
{
|
||||||
taskENTER_CRITICAL();
|
taskENTER_CRITICAL();
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void exit_critical_wrapper(uint32_t tmp)
|
static void IRAM_ATTR exit_critical_wrapper(uint32_t tmp)
|
||||||
{
|
{
|
||||||
taskEXIT_CRITICAL();
|
taskEXIT_CRITICAL();
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user