mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-08-01 08:54:14 -04:00
Kernel changes to improve power saving:
+ The timer task now blocks indefinitely if there are no timers active, allowing eTaskConfirmSleepModeStatus to return eNoTasksWaitingTimeout when configUSE_TIMERS is set to 1. + The next unblock time is calculated automatically after a task unblocks when waiting for a notification, allowing deep sleep to be entered earlier.
This commit is contained in:
parent
067c1573c3
commit
267dc24bb3
9 changed files with 96 additions and 43 deletions
|
@ -192,7 +192,7 @@ void vPortTaskUsesFPU( void );
|
|||
#endif /* configASSERT */
|
||||
|
||||
#define portNOP() __asm volatile( "NOP" )
|
||||
|
||||
#define portINLINE __inline
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* extern C */
|
||||
|
|
|
@ -137,7 +137,7 @@ ensure API function and interrupt entry is as fast and as simple as possible. */
|
|||
#ifdef configASSERT
|
||||
#define portDISABLE_INTERRUPTS() \
|
||||
{ \
|
||||
uint32_t ulStatus; \
|
||||
uint32_t ulStatus; \
|
||||
\
|
||||
/* Mask interrupts at and below the kernel interrupt priority. */ \
|
||||
ulStatus = _CP0_GET_STATUS(); \
|
||||
|
@ -152,7 +152,7 @@ ensure API function and interrupt entry is as fast and as simple as possible. */
|
|||
#else /* configASSERT */
|
||||
#define portDISABLE_INTERRUPTS() \
|
||||
{ \
|
||||
uint32_t ulStatus; \
|
||||
uint32_t ulStatus; \
|
||||
\
|
||||
/* Mask interrupts at and below the kernel interrupt priority. */ \
|
||||
ulStatus = _CP0_GET_STATUS(); \
|
||||
|
@ -163,7 +163,7 @@ ensure API function and interrupt entry is as fast and as simple as possible. */
|
|||
|
||||
#define portENABLE_INTERRUPTS() \
|
||||
{ \
|
||||
uint32_t ulStatus; \
|
||||
uint32_t ulStatus; \
|
||||
\
|
||||
/* Unmask all interrupts. */ \
|
||||
ulStatus = _CP0_GET_STATUS(); \
|
||||
|
@ -210,7 +210,7 @@ extern void vPortClearInterruptMaskFromISR( UBaseType_t );
|
|||
|
||||
#define portYIELD() \
|
||||
{ \
|
||||
uint32_t ulCause; \
|
||||
uint32_t ulCause; \
|
||||
\
|
||||
/* Trigger software interrupt. */ \
|
||||
ulCause = _CP0_GET_CAUSE(); \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue