base: document specifics of Slab::alloc()

Also removed unimplemented overload of alloc() with no parameters.
This commit is contained in:
Christian Helmuth 2014-10-16 14:59:26 +02:00
parent e708bbe2c6
commit 2eca4ec98b
1 changed files with 9 additions and 7 deletions

View File

@ -216,11 +216,6 @@ namespace Genode {
*/
void insert_sb(Slab_block *sb, Slab_block *at = 0);
/**
* Allocate slab entry
*/
void *alloc();
/**
* Free slab entry
*/
@ -242,10 +237,17 @@ namespace Genode {
void backing_store(Allocator *bs) { _backing_store = bs; }
Allocator *backing_store() { return _backing_store; }
/*************************
** Allocator interface **
*************************/
/**
* Allocator interface
* Allocate slab entry
*
* The 'size' parameter is ignored as only slab entries with
* preconfigured slab-entry size are allocated.
*/
bool alloc(size_t, void **);
bool alloc(size_t size, void **addr);
void free(void *addr, size_t) { free(addr); }
size_t consumed();
size_t overhead(size_t) { return _block_size/_num_elem; }