FreeRTOS-Kernel/include
Darian Leung 6ac7cc844b change(freertos/smp): Update tasks.c locking
Updated critical section macros with granular locks.

Some tasks.c API relied on their callers to enter critical sections. This
assumption no longer works under granular locking. Critical sections added to
the following functions:

- `vTaskInternalSetTimeOutState()`
- `xTaskIncrementTick()`
- `vTaskSwitchContext()`
- `xTaskRemoveFromEventList()`
- `vTaskInternalSetTimeOutState()`
- `eTaskConfirmSleepModeStatus()`
- `xTaskPriorityDisinherit()`
- `pvTaskIncrementMutexHeldCount()`

Added missing suspensions to the following functions:

- `vTaskPlaceOnEventList()`
- `vTaskPlaceOnUnorderedEventList()`
- `vTaskPlaceOnEventListRestricted()`

Fixed the locking in vTaskSwitchContext()

vTaskSwitchContext() must aquire both kernel locks, viz., task lock and
ISR lock. This is because, vTaskSwitchContext() can be called from
either task context or ISR context. Also, vTaskSwitchContext() must not
alter the interrupt state prematurely.

Co-authored-by: Sudeep Mohanty <sudeep.mohanty@espressif.com>
2025-04-02 14:34:27 +02:00
..
atomic.h Use Regex for Copyright Year in Header Check (#1002) 2024-02-26 09:26:42 -08:00
CMakeLists.txt Fix circular dependency in CMake project (#700) 2023-07-10 15:08:59 -07:00
croutine.h Use Regex for Copyright Year in Header Check (#1002) 2024-02-26 09:26:42 -08:00
deprecated_definitions.h Use Regex for Copyright Year in Header Check (#1002) 2024-02-26 09:26:42 -08:00
event_groups.h Event Groups: snapshot xEventGroupSetBits returning value while in vTaskSuspendAll (#1143) 2024-09-11 23:07:08 +05:30
FreeRTOS.h feat(granular_locks): Add granular locking functions 2025-03-31 15:26:11 +02:00
list.h Fix cmake example errors (#1037) 2024-04-18 19:08:51 +05:30
message_buffer.h Update stream and message buffer documentation (#1226) 2025-01-21 15:17:10 +05:30
mpu_prototypes.h Add xQueueCreateSetStatic method for static allocation of Queue Sets (#1228) 2025-01-22 14:53:35 +05:30
mpu_syscall_numbers.h Use Regex for Copyright Year in Header Check (#1002) 2024-02-26 09:26:42 -08:00
mpu_wrappers.h Add xQueueCreateSetStatic method for static allocation of Queue Sets (#1228) 2025-01-22 14:53:35 +05:30
newlib-freertos.h Use Regex for Copyright Year in Header Check (#1002) 2024-02-26 09:26:42 -08:00
picolibc-freertos.h Use Regex for Copyright Year in Header Check (#1002) 2024-02-26 09:26:42 -08:00
portable.h Disable stack overflow check for MPU ports (#1231) 2025-02-24 21:54:15 +05:30
projdefs.h Use Regex for Copyright Year in Header Check (#1002) 2024-02-26 09:26:42 -08:00
queue.h Add xQueueCreateSetStatic method for static allocation of Queue Sets (#1228) 2025-01-22 14:53:35 +05:30
semphr.h Use Regex for Copyright Year in Header Check (#1002) 2024-02-26 09:26:42 -08:00
stack_macros.h Disable stack overflow check for MPU ports (#1231) 2025-02-24 21:54:15 +05:30
StackMacros.h Use Regex for Copyright Year in Header Check (#1002) 2024-02-26 09:26:42 -08:00
stdint.readme Use Regex for Copyright Year in Header Check (#1002) 2024-02-26 09:26:42 -08:00
stream_buffer.h Update stream and message buffer documentation (#1226) 2025-01-21 15:17:10 +05:30
task.h change(freertos/smp): Update tasks.c locking 2025-04-02 14:34:27 +02:00
timers.h Update comment in the example for declaration of xTimerReset (#1133) 2024-09-02 21:16:23 +05:30