diff options
author | Damjan Marion <damarion@cisco.com> | 2020-10-02 15:01:12 +0200 |
---|---|---|
committer | Damjan Marion <damarion@cisco.com> | 2020-10-02 15:04:17 +0200 |
commit | 2bc1af5578a9c669c16839656bb661ce950c2246 (patch) | |
tree | 7390e803f9d5fb0d698976a5c5ac682d7d59de52 /src/vlib/threads.c | |
parent | eb530a24b4ec2b055f5ef40f4b01ca4579dd87b0 (diff) |
vppinfra: use clib_mem_create_heap() to create numa heap(s)
Type: improvement
Change-Id: Ie04302c576869bc7bfaa9f13ed2ea8a403a393d4
Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vlib/threads.c')
-rw-r--r-- | src/vlib/threads.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/vlib/threads.c b/src/vlib/threads.c index 0fc306db6f2..270ccc325ba 100644 --- a/src/vlib/threads.c +++ b/src/vlib/threads.c @@ -640,8 +640,11 @@ vlib_launch_thread_int (void *fp, vlib_worker_thread_t * w, unsigned cpu_id) /* If the user requested a NUMA heap, create it... */ if (tm->numa_heap_size) { - numa_heap = clib_mem_init_thread_safe_numa - (0 /* DIY */ , tm->numa_heap_size, w->numa_id); + clib_mem_set_numa_affinity (w->numa_id, 1 /* force */ ); + numa_heap = clib_mem_create_heap (0 /* DIY */ , tm->numa_heap_size, + 1 /* is_locked */ , + "numa %u heap", w->numa_id); + clib_mem_set_default_numa_affinity (); mm->per_numa_mheaps[w->numa_id] = numa_heap; } else |