mem: provide thread-unsafe memseg walk variant
authorAnatoly Burakov <anatoly.burakov@intel.com>
Tue, 12 Jun 2018 09:46:15 +0000 (10:46 +0100)
committerThomas Monjalon <thomas@monjalon.net>
Fri, 13 Jul 2018 09:21:15 +0000 (11:21 +0200)
commit7c790af08fb8a6b1757c92118f780c9a336b951b
tree702d6e456970f749949cda987d59630b609a21ac
parentb917147601ea4b890f8331c42a13df3cda8d187d
mem: provide thread-unsafe memseg walk variant

Sometimes, user code needs to walk memseg list while being inside
a memory-related callback. Rather than making everyone copy around
the same iteration code and depending on DPDK internals, provide an
official way to do memseg_walk() inside callbacks.

Also, remove existing reimplementation from sPAPR VFIO code and use
the new API instead.

Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
lib/librte_eal/common/eal_common_memory.c
lib/librte_eal/common/include/rte_memory.h
lib/librte_eal/linuxapp/eal/eal_vfio.c
lib/librte_eal/rte_eal_version.map