L4Re Operating System Framework
Interface and Usage Documentation
Loading...
Searching...
No Matches
Initial Environment

C interface of the initial environment that is provided to an L4 task. More...

+ Collaboration diagram for Initial Environment:

Data Structures

struct  l4re_env_cap_entry_t
 Entry in the L4Re environment array for the named inital objects. More...
 

Typedefs

typedef struct l4re_env_cap_entry_t l4re_env_cap_entry_t
 Entry in the L4Re environment array for the named inital objects.
 

Functions

l4re_env_tl4re_env (void) L4_NOTHROW
 Get L4Re initial environment.
 
l4_kernel_info_t const * l4re_kip (void) L4_NOTHROW
 Get Kernel Info Page.
 
l4_cap_idx_t l4re_env_get_cap (char const *name) L4_NOTHROW
 Get the capability selector for the object named name.
 
l4_cap_idx_t l4re_env_get_cap_e (char const *name, l4re_env_t const *e) L4_NOTHROW
 Get the capability selector for the object named name.
 
l4re_env_cap_entry_t const * l4re_env_get_cap_l (char const *name, unsigned l, l4re_env_t const *e) L4_NOTHROW
 Get the full l4re_env_cap_entry_t for the object named name.
 

Detailed Description

C interface of the initial environment that is provided to an L4 task.

Include File
#include <l4/re/env.h>
Environment interface.

For an explanation of the default task capabilites see l4_default_caps_t.

For the C++ interface refer to L4Re::Env.

Function Documentation

◆ l4re_env()

l4re_env_t * l4re_env ( void  )
inline

Get L4Re initial environment.

Returns
Pointer to L4Re initial environment.
Examples
examples/sys/aliens/main.c, examples/sys/isr/main.c, examples/sys/singlestep/main.c, examples/sys/start-with-exc/main.c, and examples/sys/utcb-ipc/main.c.

Definition at line 190 of file env.h.

Referenced by l4re_env_get_cap().

+ Here is the caller graph for this function:

◆ l4re_env_get_cap()

l4_cap_idx_t l4re_env_get_cap ( char const *  name)
inline

Get the capability selector for the object named name.

Parameters
nameis the name of the object to lookup in the initial objects.
Returns
A valid capability selector if the object exists or an invalid capability selector if not (l4_is_invalid_cap()).

Definition at line 229 of file env.h.

References l4re_env(), and l4re_env_get_cap_e().

+ Here is the call graph for this function:

◆ l4re_env_get_cap_e()

l4_cap_idx_t l4re_env_get_cap_e ( char const *  name,
l4re_env_t const *  e 
)
inline

Get the capability selector for the object named name.

Parameters
nameis the name of the object to lookup in the initial objects.
eis the environment structure to use for the operation.
Returns
A valid capability selector if the object exists or an invalid capability selector if not (l4_is_invalid_cap()).

Definition at line 216 of file env.h.

References l4re_env_cap_entry_t::cap, L4_INVALID_CAP, and l4re_env_get_cap_l().

Referenced by l4re_env_get_cap().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ l4re_env_get_cap_l()

l4re_env_cap_entry_t const * l4re_env_get_cap_l ( char const *  name,
unsigned  l,
l4re_env_t const *  e 
)
inline

Get the full l4re_env_cap_entry_t for the object named name.

Parameters
nameis the name of the object to lookup in the initial objects.
lis the length of the name string, thus name might not be zero terminated.
eis the environment structure to use for the operation.
Returns
A pointer to an l4re_env_cap_entry_t if the object exists or NULL if not.

Definition at line 198 of file env.h.

References l4re_env_cap_entry_t::flags, and l4re_env_cap_entry_t::name.

Referenced by L4Re::Env::get(), and l4re_env_get_cap_e().

+ Here is the caller graph for this function:

◆ l4re_kip()

l4_kernel_info_t const * l4re_kip ( void  )
inline

Get Kernel Info Page.

Returns
Pointer to Kernel Info Page (KIP) structure.
Examples
examples/libs/shmc/prodcons.c, examples/sys/aliens/main.c, and examples/sys/ux-vhw/main.c.

Definition at line 194 of file env.h.

References l4_kip().

Referenced by L4::Poll_timeout_kipclock::set(), and L4::Poll_timeout_kipclock::test().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: