Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Typedefs | Functions
rheap.h File Reference
#include <linux/list.h>

Go to the source code of this file.

Data Structures

struct  _rh_block
 
struct  _rh_info
 
struct  _rh_stats
 

Macros

#define RHIF_STATIC_INFO   0x1
 
#define RHIF_STATIC_BLOCK   0x2
 
#define RHGS_FREE   0
 
#define RHGS_TAKEN   1
 

Typedefs

typedef struct _rh_block rh_block_t
 
typedef struct _rh_info rh_info_t
 
typedef struct _rh_stats rh_stats_t
 

Functions

rh_info_trh_create (unsigned int alignment)
 
void rh_destroy (rh_info_t *info)
 
void rh_init (rh_info_t *info, unsigned int alignment, int max_blocks, rh_block_t *block)
 
int rh_attach_region (rh_info_t *info, unsigned long start, int size)
 
unsigned long rh_detach_region (rh_info_t *info, unsigned long start, int size)
 
unsigned long rh_alloc_align (rh_info_t *info, int size, int alignment, const char *owner)
 
unsigned long rh_alloc (rh_info_t *info, int size, const char *owner)
 
unsigned long rh_alloc_fixed (rh_info_t *info, unsigned long start, int size, const char *owner)
 
int rh_free (rh_info_t *info, unsigned long start)
 
int rh_get_stats (rh_info_t *info, int what, int max_stats, rh_stats_t *stats)
 
void rh_dump (rh_info_t *info)
 
int rh_set_owner (rh_info_t *info, unsigned long start, const char *owner)
 

Macro Definition Documentation

#define RHGS_FREE   0

Definition at line 46 of file rheap.h.

#define RHGS_TAKEN   1

Definition at line 47 of file rheap.h.

#define RHIF_STATIC_BLOCK   0x2

Definition at line 38 of file rheap.h.

#define RHIF_STATIC_INFO   0x1

Definition at line 37 of file rheap.h.

Typedef Documentation

Function Documentation

unsigned long rh_alloc ( rh_info_t info,
int  size,
const char owner 
)

Definition at line 517 of file rheap.c.

unsigned long rh_alloc_align ( rh_info_t info,
int  size,
int  alignment,
const char owner 
)

Definition at line 442 of file rheap.c.

unsigned long rh_alloc_fixed ( rh_info_t info,
unsigned long  start,
int  size,
const char owner 
)

Definition at line 527 of file rheap.c.

int rh_attach_region ( rh_info_t info,
unsigned long  start,
int  size 
)

Definition at line 329 of file rheap.c.

rh_info_t* rh_create ( unsigned int  alignment)

Definition at line 253 of file rheap.c.

void rh_destroy ( rh_info_t info)

Definition at line 285 of file rheap.c.

unsigned long rh_detach_region ( rh_info_t info,
unsigned long  start,
int  size 
)

Definition at line 370 of file rheap.c.

void rh_dump ( rh_info_t info)

Definition at line 704 of file rheap.c.

int rh_free ( rh_info_t info,
unsigned long  start 
)

Definition at line 612 of file rheap.c.

int rh_get_stats ( rh_info_t info,
int  what,
int  max_stats,
rh_stats_t stats 
)

Definition at line 641 of file rheap.c.

void rh_init ( rh_info_t info,
unsigned int  alignment,
int  max_blocks,
rh_block_t block 
)

Definition at line 300 of file rheap.c.

int rh_set_owner ( rh_info_t info,
unsigned long  start,
const char owner 
)

Definition at line 679 of file rheap.c.