X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fvlib%2Fphysmem_funcs.h;h=d93bae8fbe5eed132ed73e446ed5d6c7a7855d0a;hb=206acf84d6a04590e385f427edba1094c3bdf195;hp=0082f85c70da24e608a071d10f33ab1198dbd555;hpb=68b4da67deb2e8ca224bb5abaeb9dbc7ae8e378c;p=vpp.git diff --git a/src/vlib/physmem_funcs.h b/src/vlib/physmem_funcs.h index 0082f85c70d..d93bae8fbe5 100644 --- a/src/vlib/physmem_funcs.h +++ b/src/vlib/physmem_funcs.h @@ -40,10 +40,15 @@ #ifndef included_vlib_physmem_funcs_h #define included_vlib_physmem_funcs_h +#include +#include +#include +#include + clib_error_t *vlib_physmem_init (vlib_main_t * vm); clib_error_t *vlib_physmem_shared_map_create (vlib_main_t * vm, char *name, - uword size, u32 numa_node, - u32 * map_index); + uword size, u32 log2_page_sz, + u32 numa_node, u32 * map_index); vlib_physmem_map_t *vlib_physmem_get_map (vlib_main_t * vm, u32 index); @@ -54,6 +59,15 @@ vlib_physmem_alloc_aligned (vlib_main_t * vm, uword n_bytes, uword alignment) return clib_pmalloc_alloc_aligned (pm, n_bytes, alignment); } +always_inline void * +vlib_physmem_alloc_aligned_on_numa (vlib_main_t * vm, uword n_bytes, + uword alignment, u32 numa_node) +{ + clib_pmalloc_main_t *pm = vm->physmem_main.pmalloc_main; + return clib_pmalloc_alloc_aligned_on_numa (pm, n_bytes, alignment, + numa_node); +} + /* By default allocate I/O memory with cache line alignment. */ always_inline void * vlib_physmem_alloc (vlib_main_t * vm, uword n_bytes)