zephyr/arch/arm/include
Benjamin Walsh 2858cbf829 idle: fix tasks waiting when NANO_TIMEOUTS is enabled
Fix an issue where, if a task is pending on a nano timeout, the duration
it wants to wait is not taken into account by the tickless idle code.
This could cause a system to wait forever, or to the limit of the timer
hardware (which is forever, for all intents and purposes).

This fix is to add one field in the nanokernel data structure for one
task to record the amount of ticks it will wait on a nano timeout. Only
one task has to be able to record this information, since, these waits
being looping busy waits, the task of highest priority is the only task
that can be actively waiting with a nano timeout. If a task of lower
priority was previously waiting, and a new task is now waiting, it means
that the wait of the original task has been interrupted, which will
cause said task to run the busy loop on the object again when it gets
scheduled, and the number of ticks it wants to wait has to be recomputed
and recorded again.

Change-Id: Ibcf0f288fc42d96897642cfee00ab7359716703f
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
2016-02-05 20:25:24 -05:00
..
cortex_m c++: Add extern "C" { } block to header files 2016-02-05 20:25:22 -05:00
asm_inline.h Change BSD-3 licenses to Apache 2 2016-02-05 20:24:29 -05:00
kernel_event_logger_arch.h c++: Add extern "C" { } block to header files 2016-02-05 20:25:22 -05:00
nano_private.h idle: fix tasks waiting when NANO_TIMEOUTS is enabled 2016-02-05 20:25:24 -05:00
start_task_arch.h c++: Add extern "C" { } block to header files 2016-02-05 20:25:22 -05:00