Browse Source
At the present time, Zephyr does has overlap between sleeping and suspending. Not only should sleeping and suspended be orthogonal states, but we should ensure users always employ the correct API. For example, to wake a sleeping thread, k_wakeup() should be used, and to resume a suspended thread, k_thread_resume() should be used. However, at the present time k_thread_resume() can be used on a thread that called k_sleep(K_FOREVER). Sleeping should have nothing to do with suspension. This commit introduces the new _THREAD_SLEEPING thread state along with some prep-work to facilitate the decoupling of the sleeping and suspended thread states. Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>pull/83187/head
6 changed files with 22 additions and 2 deletions
Loading…
Reference in new issue