Re: [dpdk-dev] [PATCH v3] mem: fix undefined behavior in NUMA code

2018-09-21 Thread Ilya Maximets
On 21.09.2018 12:27, Anatoly Burakov wrote: > When NUMA-aware hugepages config option is set, we rely on > libnuma to tell the kernel to allocate hugepages on a specific > NUMA node. However, we allocate node mask before we check if > NUMA is available in the first place, which, according to > the

[dpdk-dev] [PATCH v3] mem: fix undefined behavior in NUMA code

2018-09-21 Thread Anatoly Burakov
When NUMA-aware hugepages config option is set, we rely on libnuma to tell the kernel to allocate hugepages on a specific NUMA node. However, we allocate node mask before we check if NUMA is available in the first place, which, according to the manpage [1], causes undefined behaviour. Fix by only