mirror of
https://github.com/espressif/esp-idf
synced 2025-04-13 10:10:09 -04:00
Due to SMP, critical sections have been added to xTaskIncrementTick() and vTaskSwitchContext() (to take the xKernelLock). However, this is technically not necessary when building for single-core as FreeRTOS expect these funcitons to be called with interrupts already disabled. This commit makes the critical secitons in those functions depend on "configNUM_CORES > 1", and ensures that interrupts are disabled when calling those functions. This effectively restores the vanilla behavior for these functions when building for single-core.