Barrelfish
|
Slot allocator capable of allocating more than one slot at a time. More...
Functions | |
errval_t | range_slot_alloc (struct range_slot_allocator *alloc, cslot_t nslots, struct capref *ret) |
Allocate slots out of a cnode. More... | |
errval_t | range_slot_free (struct range_slot_allocator *alloc, struct capref cap, cslot_t nslots) |
Free slots belonging to the cnode. More... | |
errval_t | range_slot_alloc_init (struct range_slot_allocator *ret, cslot_t nslots, cslot_t *retslots) |
Constructor for a new instance of a single cnode cspace_allocator. More... | |
Slot allocator capable of allocating more than one slot at a time.
errval_t range_slot_alloc | ( | struct range_slot_allocator * | alloc, |
cslot_t | nslots, | ||
struct capref * | ret | ||
) |
Allocate slots out of a cnode.
alloc | Pointer to the metadata |
nslots | Number of slots to allocate |
ret | Pointer used to return the allocated slot |
errval_t range_slot_alloc_init | ( | struct range_slot_allocator * | ret, |
cslot_t | nslots, | ||
cslot_t * | retslots | ||
) |
Constructor for a new instance of a single cnode cspace_allocator.
ret | Instance of the allocator created |
nslots | Desired number of slots the cnode should have |
ret_slots | Number of slots actually used |
errval_t range_slot_free | ( | struct range_slot_allocator * | alloc, |
struct capref | cap, | ||
cslot_t | nslots | ||
) |
Free slots belonging to the cnode.
alloc | Pointer to the metadata |
cap | Slot to start freeing from |
nslots | Number of slots to free |