![]() |
L4Re Operating System Framework
Interface and Usage Documentation
|
All kinds of timeouts and time related functions. More...
Data Structures | |
| struct | l4_timeout_s |
| Basic timeout specification. More... | |
| union | l4_timeout_t |
| Timeout pair. More... | |
Macros | |
| #define | L4_IPC_TIMEOUT_0 ((l4_timeout_s){0x0400}) |
| Timeout constants. | |
| #define | L4_IPC_TIMEOUT_NEVER ((l4_timeout_s){0}) |
| never timeout | |
| #define | L4_IPC_NEVER_INITIALIZER {0} |
| never timeout, initializer | |
| #define | L4_IPC_NEVER ((l4_timeout_t){0}) |
| never timeout | |
| #define | L4_IPC_RECV_TIMEOUT_0 ((l4_timeout_t){0x00000400}) |
| 0 receive timeout | |
| #define | L4_IPC_SEND_TIMEOUT_0 ((l4_timeout_t){0x04000000}) |
| 0 send timeout | |
| #define | L4_IPC_BOTH_TIMEOUT_0 ((l4_timeout_t){0x04000400}) |
| 0 receive and send timeout | |
| #define | L4_TIMEOUT_US_NEVER (~0ULL) |
| The waiting period in microseconds which is interpreted as "never" by l4_timeout_from_us(). | |
| #define | L4_TIMEOUT_US_MAX ((1ULL << 41) - 1) |
| The longest waiting period in microseconds accepted by l4_timeout_from_us(). | |
Typedefs | |
| typedef struct l4_timeout_s | l4_timeout_s |
| Basic timeout specification. | |
| typedef union l4_timeout_t | l4_timeout_t |
| Timeout pair. | |
Functions | |
| L4_CONSTEXPR l4_timeout_s | l4_timeout_rel (unsigned man, unsigned exp) L4_NOTHROW |
| Get relative timeout consisting of mantissa and exponent. | |
| L4_CONSTEXPR l4_timeout_t | l4_ipc_timeout (unsigned snd_man, unsigned snd_exp, unsigned rcv_man, unsigned rcv_exp) L4_NOTHROW |
| Convert explicit timeout values to l4_timeout_t type. | |
| L4_CONSTEXPR l4_timeout_t | l4_timeout (l4_timeout_s snd, l4_timeout_s rcv) L4_NOTHROW |
| Combine send and receive timeout in a timeout. | |
| L4_CONSTEXPR void | l4_snd_timeout (l4_timeout_s snd, l4_timeout_t *to) L4_NOTHROW |
| Set send timeout in given to timeout. | |
| L4_CONSTEXPR void | l4_rcv_timeout (l4_timeout_s rcv, l4_timeout_t *to) L4_NOTHROW |
| Set receive timeout in given to timeout. | |
| L4_CONSTEXPR l4_kernel_clock_t | l4_timeout_rel_get (l4_timeout_s to) L4_NOTHROW |
| Get clock value of out timeout. | |
| L4_CONSTEXPR unsigned | l4_timeout_is_absolute (l4_timeout_s to) L4_NOTHROW |
| Return whether the given timeout is absolute or not. | |
| L4_CONSTEXPR l4_kernel_clock_t | l4_timeout_get (l4_kernel_clock_t cur, l4_timeout_s to) L4_NOTHROW |
| Get clock value for a clock + a timeout. | |
| l4_timeout_s | l4_timeout_abs (l4_kernel_clock_t pint, int br) L4_NOTHROW |
| Set an absolute timeout. | |
| unsigned | l4_utcb_mr64_idx (unsigned idx) L4_NOTHROW |
| Get index into 64bit message registers alias from native-sized index. | |
All kinds of timeouts and time related functions.
| #define L4_IPC_TIMEOUT_0 ((l4_timeout_s){0x0400}) |
Timeout constants.
0 timeout
Definition at line 73 of file __timeout.h.
Referenced by L4::Ipc_svr::Timeout_queue_hooks< HOOKS, BR_MAN >::timeout().
| #define L4_TIMEOUT_US_MAX ((1ULL << 41) - 1) |
The longest waiting period in microseconds accepted by l4_timeout_from_us().
See l4_timeout_from_us() for an explanation.
Definition at line 91 of file __timeout.h.
| typedef struct l4_timeout_s l4_timeout_s |
Basic timeout specification.
If bit 15 == 0, basically a floating point number with 10 bits mantissa and 5 bits exponent (t = m*2^e).
If the mantissa is zero, the exponent encodes special values, see L4_IPC_TIMEOUT_0 and L4_IPC_TIMEOUT_NEVER.
If bit 15 == 1 the timeout is absolute and the lower 6 bits encode the index of the UTCB buffer register(s) holding the absolute 64-bit timeout value. On 32-bit systems, two consecutive UTCB buffer registers are used.
| typedef union l4_timeout_t l4_timeout_t |
Timeout pair.
For IPC there are usually a send and a receive timeout. So this structure contains a pair of timeouts.
|
inline |
Convert explicit timeout values to l4_timeout_t type.
| snd_man | Mantissa of send timeout. |
| snd_exp | Exponent of send timeout. |
| rcv_man | Mantissa of receive timeout. |
| rcv_exp | Exponent of receive timeout. |
Definition at line 203 of file __timeout.h.
References L4_NOTHROW, and l4_timeout().
|
inline |
Set receive timeout in given to timeout.
| rcv | Receive timeout | |
| [out] | to | L4 timeout |
Definition at line 227 of file __timeout.h.
References L4_NOTHROW.
|
inline |
Set send timeout in given to timeout.
| snd | Send timeout | |
| [out] | to | L4 timeout |
Definition at line 220 of file __timeout.h.
References L4_NOTHROW.
|
inline |
Combine send and receive timeout in a timeout.
| snd | Send timeout |
| rcv | Receive timeout |
Definition at line 213 of file __timeout.h.
References L4_NOTHROW.
Referenced by l4_ipc_sleep_ms(), l4_ipc_sleep_us(), l4_ipc_timeout(), and L4::Ipc_svr::Timeout_queue_hooks< HOOKS, BR_MAN >::timeout().
|
inline |
Set an absolute timeout.
| pint | Point in time in clocks |
| br | The buffer register the timeout shall be placed in. ( |
Definition at line 389 of file utcb.h.
References L4_NOTHROW, and l4_utcb().
Referenced by L4::Ipc_svr::Timeout_queue_hooks< HOOKS, BR_MAN >::timeout().
|
inline |
Get clock value for a clock + a timeout.
| cur | Clock value |
| to | L4 timeout |
Definition at line 257 of file __timeout.h.
References L4_NOTHROW, l4_timeout_is_absolute(), and l4_timeout_rel_get().
|
inline |
Return whether the given timeout is absolute or not.
| to | L4 timeout |
Definition at line 250 of file __timeout.h.
References L4_NOTHROW.
Referenced by l4_timeout_get().
|
inline |
Get relative timeout consisting of mantissa and exponent.
| man | Mantissa of timeout |
| exp | Exponent of timeout |
Definition at line 234 of file __timeout.h.
References L4_NOTHROW.
|
inline |
Get clock value of out timeout.
| to | L4 timeout |
Definition at line 241 of file __timeout.h.
References L4_NOTHROW.
Referenced by l4_timeout_get().
|
inline |
Get index into 64bit message registers alias from native-sized index.
| idx | Index to native-sized message register |
Definition at line 392 of file utcb.h.
References L4_INLINE, and L4_NOTHROW.
Referenced by l4_icu_msi_info_u().