/tmp/l4check/full_tree/trunk/l4/pkg/dde_linux/lib/src/slab.c File Reference

Very simple emulation of linux slabs (kmem_cache). More...

#include <l4/slab/slab.h>
#include <l4/log/l4log.h>
#include <l4/dm_mem/dm_mem.h>
#include <l4/dde_linux/dde.h>
#include <linux/slab.h>
#include "__config.h"
#include "internal.h"

Go to the source code of this file.

Classes

struct  kmem_cache_s
 local kmem_cache to L4 slab_cache mapping More...

Defines

#define CACHE_NAMELEN   20

Functions

static void * alloc_grow (l4slab_cache_t *cache, void **data)
 Grow slab cache (allocate new memory for slabs)
  • one page (L4_PAGESIZE) will be added.

kmem_cache_t * kmem_cache_create (const char *name, size_t size, size_t offset, unsigned long flags, void(*ctor)(void *, kmem_cache_t *, unsigned long), void(*dtor)(void *, kmem_cache_t *, unsigned long))
 Create slab cache

It's from mm/slab.c.

int kmem_cache_destroy (kmem_cache_t *kcache)
 Finalize slab cache.
void * kmem_cache_alloc (kmem_cache_t *kcache, int flags)
 Allocate slab in cache.
void kmem_cache_free (kmem_cache_t *kcache, void *objp)
 Free slab in cache.


Detailed Description

Very simple emulation of linux slabs (kmem_cache).

Date:
08/28/2003
Author:
Gerd Grießbach <gg5@os.inf.tu-dresden.de>

Christian Helmuth <ch12@os.inf.tu-dresden.de>

Definition in file slab.c.


Linux DDE, written by Christian Helmuth  © 2003 Technische Universitaet Dresden