648 return f.raw & L4_FPAGE_ADDR_MASK;
654 return f.raw & L4_FPAGE_ADDR_MASK;
659__l4_fpage_generic(
unsigned long address,
unsigned int type,
660 unsigned int order,
unsigned char rights)
L4_NOTHROW;
663__l4_fpage_generic(
unsigned long address,
unsigned int type,
664 unsigned int order,
unsigned char rights)
L4_NOTHROW
670 | ((address ) & L4_FPAGE_ADDR_MASK);
678 f.
raw = ((L4_FPAGE_TYPE_MASK | L4_FPAGE_SIZE_MASK | L4_FPAGE_ADDR_MASK) & src.raw)
699 "Capability index does not fit into fpage.");
700 return __l4_fpage_generic(obj,
L4_FPAGE_OBJ, order, rights);
740 && (fa + (1UL <<
l4_fpage_size(fpage)) >= addr + (1UL << log2size));
755 if (base + (1UL << (order + 1)) - 1 > max_addr - 1)
758 mask = ~(~0UL << (order + 1));
759 if (hotspot == ~0UL || ((addr ^ hotspot) & mask))
L4 compiler related defines.
unsigned long l4_umword_t
Unsigned machine word.
unsigned long l4_addr_t
Address type.
#define L4_MWORD_BITS
Size of machine words in bits.
unsigned long l4_cap_idx_t
Capability selector type.
@ L4_CAP_SHIFT
Capability index shift.
unsigned long l4_fpage_page(l4_fpage_t f) L4_NOTHROW
Return the page part from a flexpage.
int l4_fpage_contains(l4_fpage_t fpage, l4_addr_t addr, unsigned order) L4_NOTHROW
Test whether a given range is completely within an fpage.
l4_fpage_t l4_obj_fpage(l4_cap_idx_t obj, unsigned int order, unsigned char rights) L4_NOTHROW
Create a kernel-object flexpage.
l4_fpage_t l4_fpage_all(void) L4_NOTHROW
Get a flexpage, describing all address spaces at once.
l4_fpage_t l4_fpage_set_rights(l4_fpage_t src, unsigned char new_rights) L4_NOTHROW
Set new right in a flexpage.
L4_fpage_rights
Memory and IO port flexpage rights.
L4_fpage_control
Flexpage map control flags.
unsigned l4_fpage_type(l4_fpage_t f) L4_NOTHROW
Return type from a flexpage.
unsigned long l4_fpage_ioport(l4_fpage_t f) L4_NOTHROW
Return the IO port number from the IO flexpage.
l4_addr_t l4_fpage_memaddr(l4_fpage_t f) L4_NOTHROW
Return the memory address from the memory flexpage.
l4_fpage_t l4_fpage(l4_addr_t address, unsigned int order, unsigned char rights) L4_NOTHROW
Create a memory flexpage.
unsigned l4_fpage_size(l4_fpage_t f) L4_NOTHROW
Return size (log2) from a flexpage.
unsigned char l4_fpage_max_order(unsigned char order, l4_addr_t addr, l4_addr_t min_addr, l4_addr_t max_addr, l4_addr_t hotspot=0)
Determine maximum flexpage size of a region.
unsigned l4_fpage_rights(l4_fpage_t f) L4_NOTHROW
Return rights from a flexpage.
l4_fpage_t l4_iofpage(unsigned long port, unsigned int order) L4_NOTHROW
Create an IO-port flexpage.
int l4_is_fpage_writable(l4_fpage_t fp) L4_NOTHROW
Test if the flexpage is writable.
L4_fpage_type
Flexpage type.
l4_fpage_t l4_fpage_invalid(void) L4_NOTHROW
Get an invalid flexpage.
l4_cap_idx_t l4_fpage_obj(l4_fpage_t f) L4_NOTHROW
Return the capability index from the object flexpage.
L4_cap_fpage_rights
Object flexpage rights.
L4_fpage_consts
L4 flexpage structure.
@ L4_WHOLE_IOADDRESS_SPACE
Whole I/O address space size.
@ L4_IOPORT_MAX
Maximum I/O port address plus 1.
@ L4_WHOLE_ADDRESS_SPACE
Whole address space size.
@ L4_FPAGE_X
Executable flexpage.
@ L4_FPAGE_RWX
Read-write-execute flexpage.
@ L4_FPAGE_RX
Read-execute flexpage.
@ L4_FPAGE_RO
Read-only flexpage
@ L4_FPAGE_RW
Read-write flexpage.
@ L4_FPAGE_W
Writable flexpage.
@ L4_FPAGE_CONTROL_MASK
Mask for truncating the lower bits of the send base or the index of the control word.
@ L4_FPAGE_CONTROL_OFFSET_SHIFT
Number of bits an index must be shifted or an address must be aligned to in the control word.
@ L4_FPAGE_MEMORY
Flexpage for memory spaces.
@ L4_FPAGE_IO
Flexpage for I/O port spaces.
@ L4_FPAGE_OBJ
Flexpage for object spaces.
@ L4_FPAGE_SPECIAL
Special flexpage, either l4_fpage_invalid() or l4_fpage_all(); only supported by selected interfaces.
@ L4_CAP_FPAGE_RO
Read right for capability flexpages.
@ L4_CAP_FPAGE_R
Read right for capability flexpages.
@ L4_CAP_FPAGE_RW
Read and interface specific 'W' right for capability flexpages.
@ L4_CAP_FPAGE_W
Interface specific 'W' right for capability flexpages.
@ L4_CAP_FPAGE_RS
Read and interface specific 'S' right for capability flexpages.
@ L4_CAP_FPAGE_RWSD
Full rights for capability flexpages.
@ L4_CAP_FPAGE_RSD
Read, 'S', and delete right for capability flexpages.
@ L4_CAP_FPAGE_RWS
Read, interface specific 'W', and 'S' rights for capability flexpages.
@ L4_CAP_FPAGE_D
Delete right for capability flexpages.
@ L4_CAP_FPAGE_S
Interface specific 'S' right for capability flexpages.
@ L4_CAP_FPAGE_RWD
Read, write, and delete right for capability flexpages.
@ L4_FPAGE_ADDR_SHIFT
Page address shift.
@ L4_FPAGE_TYPE_SHIFT
Flexpage type shift (memory, IO port, obj...)
@ L4_FPAGE_RIGHTS_MASK
Mask to get the flexpage rights.
@ L4_FPAGE_TYPE_BITS
Flexpage type size (memory, IO port, obj...)
@ L4_FPAGE_RIGHTS_BITS
Access permissions size.
@ L4_FPAGE_RIGHTS_ALL
Specify as flexpage rights during grant.
@ L4_FPAGE_ADDR_BITS
Page address size.
@ L4_FPAGE_SIZE_BITS
Flexpage size size (log2-based)
@ L4_FPAGE_RIGHTS_SHIFT
Access permissions shift.
@ L4_FPAGE_SIZE_SHIFT
Flexpage size shift (log2-based)
l4_addr_t l4_trunc_size(l4_addr_t address, unsigned char bits) L4_NOTHROW
Round an address down to the next lower flexpage with size bits.
l4_umword_t l4_map_control(l4_umword_t spot, unsigned char cache, unsigned grant) L4_NOTHROW
Create the first word for a map item that is a send item for the memory space.
l4_fpage_cacheability_opt_t
Cacheability options for memory send items.
l4_umword_t l4_map_obj_control(l4_umword_t spot, unsigned grant) L4_NOTHROW
Create the first word for a map item that is a send item for the object space.
L4_obj_fpage_ctl
Attributes and additional permissions for object send items.
@ L4_FPAGE_CACHEABLE
Cacheability option to enable caches for the mapping.
@ L4_FPAGE_CACHE_OPT
Enable the cacheability option in a memory send item.
@ L4_FPAGE_UNCACHEABLE
Cacheability option to disable caching for the mapping.
@ L4_FPAGE_BUFFERABLE
Cacheability option to enable buffered writes for the mapping.
@ L4_ITEM_MAP
Identify a message item as map item.
@ L4_FPAGE_C_NO_REF_CNT
Don't increase the reference counter.
@ L4_FPAGE_C_OBJ_RIGHT1
Object-type specific right.
@ L4_FPAGE_C_IPCGATE_SVR
The receiver may invoke IPC-gate-specific functions on the capability, e.g.
@ L4_FPAGE_C_OBJ_RIGHT2
Object-type specific right.
@ L4_FPAGE_C_OBJ_RIGHT3
Object-type specific right.
@ L4_FPAGE_C_OBJ_RIGHTS
All Object-type specific right bits.
@ L4_FPAGE_C_REF_CNT
Mapping is reference-counted (default).
#define L4_NOTHROW
Mark a function declaration and definition as never throwing an exception.
#define L4_INLINE
L4 Inline function attribute.
l4_fpage_t fpage
Source flexpage descriptor.
l4_umword_t snd_base
Offset in receive window (send base)
l4_umword_t raw
Raw value.
l4_umword_t fpage
Raw value.