From 2ac7008a1620566fc0f7bdd33d6df24e12f56e86 Mon Sep 17 00:00:00 2001 From: tgotic Date: Tue, 27 Sep 2022 09:37:06 +0200 Subject: [PATCH] intr_alloc: Fixed missing portEXIT_CRITICAL_SAFE Closes https://github.com/espressif/esp-idf/pull/9867 [darian@espressif.com: Updated commit message] Signed-off-by: Darian Leung --- components/esp_hw_support/intr_alloc.c | 1 + 1 file changed, 1 insertion(+) diff --git a/components/esp_hw_support/intr_alloc.c b/components/esp_hw_support/intr_alloc.c index e97adc0953..314fe9db7d 100644 --- a/components/esp_hw_support/intr_alloc.c +++ b/components/esp_hw_support/intr_alloc.c @@ -801,6 +801,7 @@ esp_err_t IRAM_ATTR esp_intr_enable(intr_handle_t handle) } else { //Re-enable using cpu int ena reg if (handle->vector_desc->cpu != esp_cpu_get_core_id()) { + portEXIT_CRITICAL_SAFE(&spinlock); return ESP_ERR_INVALID_ARG; //Can only enable these ints on this cpu } ESP_INTR_ENABLE(handle->vector_desc->intno);