e_block_thread Kernel Service

Purpose

Blocks the calling kernel thread.

Syntax

#include <sys/sleep.h>
int e_block_thread ()

Description

The e_block_thread kernel service blocks the calling kernel thread. The thread must have issued a request to sleep (by calling the e_assert_wait kernel service). If it has been removed from its event list, it remains runnable.

Execution Environment

The e_block_thread kernel service can be called from the process environment only.

Return Values

The e_block_thread kernel service return a value that indicate how the thread was awakened. The following values are defined:

Item Description
THREAD_AWAKENED Denotes a normal wakeup; the event occurred.
THREAD_INTERRUPTED Denotes an interruption by a signal.
THREAD_TIMED_OUT Denotes a timeout expiration.
THREAD_OTHER Delineates the predefined system codes from those that need to be defined at the subsystem level. Subsystem should define their own values greater than or equal to this value.