L4Re - L4 Runtime Environment
Kernel Interface Page API
+ Collaboration diagram for Kernel Interface Page API:

Files

file  kip.h
 

Macros

#define l4util_kip_for_each_feature(s)   for (s += strlen(s) + 1; *s; s += strlen(s) + 1)
 Cycle through kernel features given in the KIP. More...
 

Functions

int l4util_kip_kernel_is_ux (l4_kernel_info_t *)
 Return whether the kernel is running native or under UX. More...
 
int l4util_kip_kernel_has_feature (l4_kernel_info_t *, const char *str)
 Check if kernel supports a feature. More...
 
unsigned long l4util_kip_kernel_abi_version (l4_kernel_info_t *)
 Return kernel ABI version. More...
 
l4_addr_t l4util_memdesc_vm_high (l4_kernel_info_t *kinfo)
 Return end of virtual memory. More...
 

Detailed Description

Macro Definition Documentation

◆ l4util_kip_for_each_feature

#define l4util_kip_for_each_feature (   s)    for (s += strlen(s) + 1; *s; s += strlen(s) + 1)

Cycle through kernel features given in the KIP.

Cycles through all KIP kernel feature strings. s must be a character pointer (char *) initialized with l4util_kip_version_string().

Definition at line 74 of file kip.h.

Function Documentation

◆ l4util_kip_kernel_abi_version()

unsigned long l4util_kip_kernel_abi_version ( l4_kernel_info_t )

Return kernel ABI version.

Returns
Kernel ABI version.

◆ l4util_kip_kernel_has_feature()

int l4util_kip_kernel_has_feature ( l4_kernel_info_t ,
const char *  str 
)

Check if kernel supports a feature.

Parameters
strFeature name to check.
Returns
1 if the kernel supports the feature, 0 if not.

Checks the feature field in the KIP for the given string. The KIP will be mapped if not already mapped. The KIP will not be unmapped again.

◆ l4util_kip_kernel_is_ux()

int l4util_kip_kernel_is_ux ( l4_kernel_info_t )

Return whether the kernel is running native or under UX.

Returns whether the kernel is running natively or under UX. The KIP will be mapped if not already mapped. The KIP will not be unmapped again.

Returns
1 when running under UX, 0 if not running under UX
Examples:
examples/sys/ux-vhw/main.c.

◆ l4util_memdesc_vm_high()

l4_addr_t l4util_memdesc_vm_high ( l4_kernel_info_t kinfo)

Return end of virtual memory.

Returns
0 if memory descriptor could not be found, last address of address space otherwise