![]() |
L4Re Operating System Framework
Interface and Usage Documentation
|
C++ L4 kernel thread group interface, see Thread groups for the C interface. More...
#include <thread_group>
Public Member Functions | |
l4_msgtag_t | add (Cap< Thread > thread, l4_utcb_t *utcb=l4_utcb()) noexcept |
Add thread to a thread group. | |
l4_msgtag_t | remove (Cap< Thread > thread, l4_utcb_t *utcb=l4_utcb()) noexcept |
Remove thread from a thread group. |
Additional Inherited Members | |
Protected Types inherited from L4::Kobject_t< Thread_group, Snd_destination, L4_PROTO_THREAD_GROUP, Type_info::Demand_t< 1 > > | |
typedef Thread_group | Class |
The target interface type (inheriting from Kobject_t). | |
typedef Typeid::Iface< PROTO, Thread_group > | __Iface |
The interface description for the derived class. | |
typedef Typeid::Merge_list< Typeid::Iface_list< __Iface >, typename Snd_destination::__Iface_list > | __Iface_list |
The list of all RPC interfaces provided directly or through inheritance. | |
Protected Member Functions inherited from L4::Kobject_t< Thread_group, Snd_destination, L4_PROTO_THREAD_GROUP, Type_info::Demand_t< 1 > > | |
L4::Cap< Class > | c () const noexcept |
Get the capability to ourselves. | |
Static Protected Member Functions inherited from L4::Kobject_t< Thread_group, Snd_destination, L4_PROTO_THREAD_GROUP, Type_info::Demand_t< 1 > > | |
static void | __check_protocols__ () noexcept |
Helper to check for protocol conflicts. |
C++ L4 kernel thread group interface, see Thread groups for the C interface.
An L4 thread group is a collection of threads used as indirection for IPC gate and IRQ objects such that these objects can have multiple receivers, from which the kernel selects one according to a policy.
The primary use case for thread groups are multi-threaded servers and CPU core local IRQ / IPC delivery.
A thread can be bound to at most one thread group. Before binding a thread to a thread group, the thread must be bound to a task. All threads bound to the same thread group must belong to the same task.
Definition at line 34 of file thread_group.
|
inlinenoexcept |
Add thread to a thread group.
thread | Thread to add to the thread group. |
utcb | UTCB to be used for this operation, shall be the UTCB of the calling thread. Defaults to l4_utcb. |
L4_EOK | No error occurred. |
-L4_EINVAL | thread is not a thread object. |
-L4_EEXIST | thread already bound to this thread group. |
-L4_EBUSY | thread already bound to a different thread group. |
-L4_ENOENT | Thread group doesn't exist. |
Definition at line 53 of file thread_group.
References L4::Cap_base::cap(), and L4::Kobject::cap().
|
inlinenoexcept |
Remove thread from a thread group.
thread | Thread to remove from the thread group. |
utcb | UTCB to be used for this operation, shall be the UTCB of the calling thread. Defaults to l4_utcb. |
L4_EOK | No error occurred. |
-L4_EINVAL | thread is not a thread object. |
Definition at line 67 of file thread_group.
References L4::Cap_base::cap(), and L4::Kobject::cap().