Spdk/lib/env_dpdk
Vitaliy Mysak d4653a31e0 env_dpdk: dont treat NULL as error in spdk_map_bar_rte()
We use `spdk_map_bar_rte()` to read mapped addresses
from PCI BARs.
This function is currently checking for NULL in each pair.
But in PCI memory, some registers can be left unused,
in which case they are set to 0.
As a result, we may read some NULL pointers from BARs,
which is OK.
To check if given address is indeed invalid, we should first
check if it is used.
So it is best to delegate such checks to the
user of this function.
In fact, users already do the NULL check where it is needed
(ex: virtio_pci.c:390, nvme_pcie.c:589)
so this patch just removes them from `spdk_map_bar_rte()`.

This solves github issue #1206

Change-Id: I88021ceca1b9e9d503b224f790819999cd16da01
Signed-off-by: Vitaliy Mysak <vitaliy.mysak@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/1129
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2020-03-05 13:31:50 +00:00
..
env_internal.h env_dpdk: tell spdk_mem_map_init whether legacy_mem was specified 2019-12-11 11:05:10 +00:00
env.c env: add a new function for printing memory layout 2019-12-13 11:05:57 +00:00
env.mk env_dpdk: add functions to define dpdk_env make variables 2019-10-01 14:01:58 +00:00
init.c env_dpdk: fix potential null dereference 2020-02-06 09:45:42 +00:00
Makefile lib/env_dpdk: Added VMD PCI driver object 2019-05-29 20:35:11 +00:00
memory.c memory: reverse the order of calling mem_map unregister cb 2020-02-17 10:05:10 +00:00
pci_ioat.c ioat: add device IDs for new CB-DMA engines 2019-02-26 06:50:52 +00:00
pci_nvme.c pci: remove nvme-specific attach functions 2018-12-07 17:24:19 +00:00
pci_virtio.c pci: remove virtio-specific attach functions 2018-12-07 17:24:19 +00:00
pci_vmd.c lib/env_dpdk: Added VMD PCI driver object 2019-05-29 20:35:11 +00:00
pci.c env_dpdk: dont treat NULL as error in spdk_map_bar_rte() 2020-03-05 13:31:50 +00:00
threads.c env: drop DPDK 16.07 support 2018-11-30 19:59:34 +00:00