vppinfra: make set_mempolicy failure non-critical unless NUMA_FORCE is set

Change-Id: I6c1c855cf5fc2ee06f1c7ddd6576ca16cd556fdd
Signed-off-by: Damjan Marion <damarion@cisco.com>
This commit is contained in:
Damjan Marion
2018-04-18 09:21:24 +02:00
committed by Neale Ranns
parent 63777e599a
commit 915e3f189a

View File

@ -213,7 +213,8 @@ clib_mem_vm_ext_alloc (clib_mem_vm_alloc_t * a)
u64 mask[16] = { 0 };
mask[0] = 1 << a->numa_node;
rv = set_mempolicy (MPOL_BIND, mask, sizeof (mask) * 8 + 1);
if (rv)
if (rv == -1 && a->numa_node != 0 &&
(a->flags & CLIB_MEM_VM_F_NUMA_FORCE) != 0)
{
err = clib_error_return_unix (0, "set_mempolicy");
goto error;