FD.io VPP  v19.01.2-3-gf61a1a8
Vector Packet Processing
pmalloc.c File Reference
+ Include dependency graph for pmalloc.c:

Go to the source code of this file.

Macros

#define DEFAULT_RESERVED_MB   256
 

Functions

static clib_pmalloc_chunk_tget_chunk (clib_pmalloc_page_t *pp, u32 index)
 
static uword pmalloc_size2pages (uword size, u32 log2_page_sz)
 
static int pmalloc_validate_numa_node (u32 *numa_node)
 
int clib_pmalloc_init (clib_pmalloc_main_t *pm, uword base_addr, uword size)
 
static void * alloc_chunk_from_page (clib_pmalloc_main_t *pm, clib_pmalloc_page_t *pp, u32 n_blocks, u32 block_align, u32 numa_node)
 
static void pmalloc_update_lookup_table (clib_pmalloc_main_t *pm, u32 first, u32 count)
 
static clib_pmalloc_page_tpmalloc_map_pages (clib_pmalloc_main_t *pm, clib_pmalloc_arena_t *a, u32 numa_node, u32 n_pages)
 
void * clib_pmalloc_create_shared_arena (clib_pmalloc_main_t *pm, char *name, uword size, u32 log2_page_sz, u32 numa_node)
 
static void * clib_pmalloc_alloc_inline (clib_pmalloc_main_t *pm, clib_pmalloc_arena_t *a, uword size, uword align, u32 numa_node)
 
void * clib_pmalloc_alloc_aligned_on_numa (clib_pmalloc_main_t *pm, uword size, uword align, u32 numa_node)
 
void * clib_pmalloc_alloc_aligned (clib_pmalloc_main_t *pm, uword size, uword align)
 
void * clib_pmalloc_alloc_from_arena (clib_pmalloc_main_t *pm, void *arena_va, uword size, uword align)
 
static int pmalloc_chunks_mergeable (clib_pmalloc_arena_t *a, clib_pmalloc_page_t *pp, u32 ci1, u32 ci2)
 
void clib_pmalloc_free (clib_pmalloc_main_t *pm, void *va)
 
static u8format_log2_page_size (u8 *s, va_list *va)
 
static u8format_pmalloc_page (u8 *s, va_list *va)
 
u8format_pmalloc (u8 *s, va_list *va)
 
u8format_pmalloc_map (u8 *s, va_list *va)
 

Macro Definition Documentation

#define DEFAULT_RESERVED_MB   256

Definition at line 35 of file pmalloc.c.

Function Documentation

static void* alloc_chunk_from_page ( clib_pmalloc_main_t pm,
clib_pmalloc_page_t pp,
u32  n_blocks,
u32  block_align,
u32  numa_node 
)
inlinestatic

Definition at line 116 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void* clib_pmalloc_alloc_aligned ( clib_pmalloc_main_t pm,
uword  size,
uword  align 
)

Definition at line 524 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void* clib_pmalloc_alloc_aligned_on_numa ( clib_pmalloc_main_t pm,
uword  size,
uword  align,
u32  numa_node 
)

Definition at line 517 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void* clib_pmalloc_alloc_from_arena ( clib_pmalloc_main_t pm,
void *  arena_va,
uword  size,
uword  align 
)

Definition at line 531 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static void* clib_pmalloc_alloc_inline ( clib_pmalloc_main_t pm,
clib_pmalloc_arena_t a,
uword  size,
uword  align,
u32  numa_node 
)
inlinestatic

Definition at line 462 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void* clib_pmalloc_create_shared_arena ( clib_pmalloc_main_t pm,
char *  name,
uword  size,
u32  log2_page_sz,
u32  numa_node 
)

Definition at line 415 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void clib_pmalloc_free ( clib_pmalloc_main_t pm,
void *  va 
)

Definition at line 561 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int clib_pmalloc_init ( clib_pmalloc_main_t pm,
uword  base_addr,
uword  size 
)

Definition at line 63 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static u8* format_log2_page_size ( u8 s,
va_list *  va 
)
static

Definition at line 613 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u8* format_pmalloc ( u8 s,
va_list *  va 
)

Definition at line 668 of file pmalloc.c.

+ Here is the call graph for this function:

u8* format_pmalloc_map ( u8 s,
va_list *  va 
)

Definition at line 716 of file pmalloc.c.

+ Here is the call graph for this function:

static u8* format_pmalloc_page ( u8 s,
va_list *  va 
)
static

Definition at line 631 of file pmalloc.c.

+ Here is the call graph for this function:

static clib_pmalloc_chunk_t* get_chunk ( clib_pmalloc_page_t pp,
u32  index 
)
inlinestatic

Definition at line 39 of file pmalloc.c.

+ Here is the caller graph for this function:

static int pmalloc_chunks_mergeable ( clib_pmalloc_arena_t a,
clib_pmalloc_page_t pp,
u32  ci1,
u32  ci2 
)
inlinestatic

Definition at line 539 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static clib_pmalloc_page_t* pmalloc_map_pages ( clib_pmalloc_main_t pm,
clib_pmalloc_arena_t a,
u32  numa_node,
u32  n_pages 
)
inlinestatic

Definition at line 255 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static uword pmalloc_size2pages ( uword  size,
u32  log2_page_sz 
)
inlinestatic

Definition at line 45 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static void pmalloc_update_lookup_table ( clib_pmalloc_main_t pm,
u32  first,
u32  count 
)
static

Definition at line 213 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static int pmalloc_validate_numa_node ( u32 numa_node)
inlinestatic

Definition at line 51 of file pmalloc.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function: