diff options
author | Damjan Marion <damarion@cisco.com> | 2022-03-18 12:28:35 +0100 |
---|---|---|
committer | Damjan Marion <damarion@cisco.com> | 2022-03-18 14:15:29 +0100 |
commit | 86bbdf926c6d642e789ad6dce6534c23820f3c63 (patch) | |
tree | db764b29b24a369fb576b116bbb426502a04ad1f /src/vppinfra/pool.h | |
parent | 762cfd408b16b6ab43ade3ab491292b93bdeb9b3 (diff) |
vppinfra: fixed pool from heap
Immediate benefit is ability to use hugepage backed memory.
Type: improvement
Change-Id: Ibcae961aa09ea92d3e931a40bedbc6346a4b2039
Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vppinfra/pool.h')
-rw-r--r-- | src/vppinfra/pool.h | 19 |
1 files changed, 2 insertions, 17 deletions
diff --git a/src/vppinfra/pool.h b/src/vppinfra/pool.h index 35c8e1e7b30..7d42f6c1e0d 100644 --- a/src/vppinfra/pool.h +++ b/src/vppinfra/pool.h @@ -61,10 +61,6 @@ typedef struct /** Maximum size of the pool, in elements */ u32 max_elts; - /** mmap segment info: base + length */ - u8 *mmap_base; - u64 mmap_size; - } pool_header_t; /** Align pool header so that pointers are naturally aligned. */ @@ -430,19 +426,8 @@ _pool_free (void *v) return v; clib_bitmap_free (p->free_bitmap); - if (p->max_elts) - { - int rv; - - rv = munmap (p->mmap_base, p->mmap_size); - if (rv) - clib_unix_warning ("munmap"); - } - else - { - vec_free (p->free_indices); - vec_free_h (v, pool_aligned_header_bytes); - } + vec_free (p->free_indices); + vec_free_h (v, pool_aligned_header_bytes); return 0; } |