]> granicus.if.org Git - esp-idf/commitdiff
crosscore_init: port*_CRITICAL vanilla FreeRTOS compliance
authorSachin Parekh <sachin.parekh@espressif.com>
Mon, 25 Mar 2019 10:39:21 +0000 (16:09 +0530)
committerSachin Parekh <sachin.parekh@espressif.com>
Mon, 13 May 2019 11:09:19 +0000 (16:39 +0530)
Signed-off-by: Sachin Parekh <sachin.parekh@espressif.com>
components/esp32/crosscore_int.c

index 3802a5600ea012dc6bab84b75ff3f0cc20de65e6..986deb2845c006b19328bc266a9ea14bcac9294f 100644 (file)
@@ -96,9 +96,9 @@ void esp_crosscore_int_init() {
 static void IRAM_ATTR esp_crosscore_int_send(int core_id, uint32_t reason_mask) {
     assert(core_id<portNUM_PROCESSORS);
     //Mark the reason we interrupt the other CPU
-    portENTER_CRITICAL(&reason_spinlock);
+    portENTER_CRITICAL_ISR(&reason_spinlock);
     reason[core_id] |= reason_mask;
-    portEXIT_CRITICAL(&reason_spinlock);
+    portEXIT_CRITICAL_ISR(&reason_spinlock);
     //Poke the other CPU.
     if (core_id==0) {
         DPORT_WRITE_PERI_REG(DPORT_CPU_INTR_FROM_CPU_0_REG, DPORT_CPU_INTR_FROM_CPU_0);