Loading...
Searching...
No Matches
L4Re Capability API
L4Re C++ Interface » L4Re Util C++ Interface
Collaboration diagram for L4Re Capability API:

## Data Structures

class | L4Re::Cap_alloc
| Capability allocator interface. More...
class | L4Re::Smart_cap_auto< Unmap_flags >
| Helper for Unique_cap and Unique_del_cap. More...
class | L4Re::Smart_count_cap< Unmap_flags >
| Helper for Ref_cap and Ref_del_cap. More...
class | L4Re::Util::Smart_cap_auto< Unmap_flags >
| Helper for Unique_cap and Unique_del_cap. More...
class | L4Re::Util::Smart_count_cap< Unmap_flags >
| Helper for Ref_cap and Ref_del_cap. More...
struct | L4Re::Util::Ref_cap< T >
| Automatic capability that implements automatic free and unmap of the capability selector. More...
struct | L4Re::Util::Ref_del_cap< T >
| Automatic capability that implements automatic free and unmap+delete of the capability selector. More...

## Functions

template<typename T>
Ref_cap< T >::Cap | L4Re::Util::make_ref_cap ()
| Allocate a capability slot and wrap it in a Ref_cap.
template<typename T>
Ref_del_cap< T >::Cap | L4Re::Util::make_ref_del_cap ()
| Allocate a capability slot and wrap it in a Ref_del_cap.
virtual | L4Re::Cap_alloc::~Cap_alloc ()=0
| Destructor.

## Variables

_Cap_alloc & | L4Re::Util::cap_alloc
| Capability allocator.

## Detailed Description

## Function Documentation

## make_ref_cap()

template<typename T>

Ref_cap< T >::Cap L4Re::Util::make_ref_cap | ( |  | ) |

Allocate a capability slot and wrap it in a Ref_cap.

Template Parameters

  T | Type of capability the slot is used for.

Definition at line 195 of file cap_alloc.

References cap_alloc.

## make_ref_del_cap()

template<typename T>

Ref_del_cap< T >::Cap L4Re::Util::make_ref_del_cap | ( |  | ) |

Allocate a capability slot and wrap it in a Ref_del_cap.

Template Parameters

  T | Type of capability the slot is used for.

Definition at line 204 of file cap_alloc.

References cap_alloc.

## Variable Documentation

## cap_alloc

_Cap_alloc& L4Re::Util::cap_alloc

extern

Capability allocator.

This is the instance of the capability allocator that is used by usual applications.

The capability allocator uses the Counting_cap_alloc, a reference-counting thread-safe capability allocator, that keeps a reference counter for each managed capability selector.

Examples
  examples/libs/l4re/c++/mem_alloc/ma+rm.cc, examples/libs/l4re/c++/shared_ds/ds_clnt.cc, examples/libs/l4re/c++/shared_ds/ds_srv.cc, and examples/libs/l4re/streammap/client.cc.

Referenced by L4Re::Util::Br_manager::alloc_buffer_demand(), L4Re::Util::Smart_count_cap< Unmap_flags >::copy(), L4Re::Util::Smart_cap_auto< Unmap_flags >::free(), L4Re::Util::Smart_count_cap< Unmap_flags >::free(), L4Re::Util::Event_t< Default_event_payload >::init(), L4Re::Util::Event_t< Default_event_payload >::init_poll(), make_ref_cap(), make_ref_del_cap(), make_shared_cap(), make_shared_del_cap(), make_unique_cap(), make_unique_del_cap(), L4Re::Util::Br_manager::realloc_rcv_cap(), and L4Re::Util::Object_registry::unregister_obj().