numam-dpdk/lib
Shahaf Shuler 237060c4ad mem: limit use of address hint
The commit below added an address hint as starting address for 64-bit
systems in case an explicit base virtual address was not set by the user.

The justification for such hint was to help devices that work in VA
mode and has a address range limitation to work smoothly with the eal
memory subsystem.

While the base address value selected may work fine for the eal
initialization, it easily breaks when trying to register external memory
using rte_extmem_register API.

Trying to register anonymous memory on RH x86_64 machine took several
minutes, during them the function eal_get_virtual_area repeatedly
scanned for a good VA candidate.

The attempt to guess which VA address will be free for mapping will
always result in not portable, error prone code:
* different application may use different libraries along w/ DPDK. One
  can never guess which library was called first and how much virtual
  memory it consumed.
* external memory can be registered at any time in the application run
  time.

In order not to break the existing secondary process design, this patch
only limits the max number of tries that will be done with the
address hint.
When the number of tries exceeds the threshold the code
will use the suggested address from kernel.

Fixes: 1df2170287 ("mem: use address hint for mapping hugepages")
Cc: stable@dpdk.org

Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
Tested-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Alejandro Lucero <alejandro.lucero@netronome.com>
2019-04-03 19:10:47 +02:00
..
librte_acl acl: fix compiler flags with meson and AVX2 runtime 2019-03-27 10:38:06 +01:00
librte_bbdev bbdev: add missing experimental tags and map entries 2018-12-19 19:36:53 +01:00
librte_bitratestats bitrate: add sanity check on parameters 2018-07-26 20:07:57 +02:00
librte_bpf build: improve dependency handling 2019-02-27 12:13:54 +01:00
librte_cfgfile fix indentation in symbol maps 2018-11-26 20:16:46 +01:00
librte_cmdline compat: merge compat library into EAL 2019-02-25 16:03:31 +01:00
librte_compressdev compressdev: add flag to specify where processing is done 2019-03-22 15:54:24 +01:00
librte_cryptodev cryptodev: remove XTS comment duplication 2019-03-22 15:54:24 +01:00
librte_distributor build: set compat lib as universal dependency 2018-01-30 21:59:00 +01:00
librte_eal mem: limit use of address hint 2019-04-03 19:10:47 +02:00
librte_efd efd: fix tail queue leak 2019-01-19 00:07:52 +01:00
librte_ethdev ethdev: add min/max MTU to device info 2019-03-29 18:57:42 +01:00
librte_eventdev doc: add notes about eventdev producer/consumer dependency 2019-03-15 06:46:50 +01:00
librte_flow_classify flow_classify: do not check for invalid socket ID 2018-10-11 10:37:45 +02:00
librte_gro gro: check invalid TCP header length 2019-01-17 22:38:54 +01:00
librte_gso gso: fix VxLAN/GRE tunnel checks 2019-01-22 17:08:21 +01:00
librte_hash hash: optimize signature compare for Arm NEON 2019-03-28 19:54:21 +01:00
librte_ip_frag ip_frag: fix IPv6 when MTU sizes not aligned to 8 bytes 2018-12-19 22:40:08 +01:00
librte_ipsec ipsec: support 3DES-CBC 2019-03-22 15:54:24 +01:00
librte_jobstats build: replace license text with SPDX tag 2018-01-30 21:58:59 +01:00
librte_kni eal: remove exec-env directory 2019-04-02 21:49:35 +02:00
librte_kvargs build: add module definition files for Windows 2019-04-03 01:21:31 +02:00
librte_latencystats latency: fix timestamp marking and latency calculation 2018-10-25 10:30:13 +02:00
librte_lpm lpm: remove recursively included header file 2019-01-28 01:47:23 +01:00
librte_mbuf mbuf: remove Intel offload checks from generic API 2019-04-02 16:42:52 +02:00
librte_member remove useless constructor headers 2018-07-12 00:00:35 +02:00
librte_mempool use appropriate EAL macro for constructors 2019-03-27 23:10:57 +01:00
librte_meter meter: fix divide by zero for RFC4115 2019-03-29 20:51:25 +01:00
librte_metrics metrics: disallow null as metric name 2018-07-26 20:30:18 +02:00
librte_net mbuf: remove Intel offload checks from generic API 2019-04-02 16:42:52 +02:00
librte_pci pci: fix parsing of address without function number 2018-11-13 17:59:42 +01:00
librte_pdump pdump: remove deprecated APIs 2018-12-19 01:25:56 +01:00
librte_pipeline net: add PPPoE ethertypes 2019-03-29 20:55:25 +01:00
librte_port port: add symmetric crypto 2018-10-12 19:33:02 +02:00
librte_power power: add bit for high frequency cores 2019-04-02 02:22:08 +02:00
librte_rawdev lib: reduce global variable usage 2018-10-29 02:34:27 +01:00
librte_reorder build: replace license text with SPDX tag 2018-01-30 21:58:59 +01:00
librte_ring ring: fix an error message 2019-04-03 18:39:16 +02:00
librte_sched sched: fix memory leak on init failure 2018-12-22 00:22:57 +01:00
librte_security security: add opaque userdata pointer into security session 2019-01-10 16:57:22 +01:00
librte_table lib/librte_table: add hash function headers 2018-10-12 17:58:53 +02:00
librte_telemetry telemetry: fix mapping of statistics 2019-04-02 02:30:53 +02:00
librte_timer timer: fix race condition 2018-12-19 20:56:09 +01:00
librte_vhost vhost/crypto: fix parens 2019-03-29 17:25:32 +01:00
Makefile build/linux: rename macro from LINUXAPP to LINUX 2019-03-12 17:31:22 +01:00
meson.build build: add workarounds for Windows helloworld 2019-04-03 01:21:31 +02:00