Spdk/lib/env_dpdk
Darek Stojaczyk 480b0b9ed8 pci: rescan the bus on device enumeration
The enumerate callback doesn't currently iterate through
any hotplugged devices, as it uses an outdated device list
underneath. What updates that list is a bus rescan, which
happens implicitly on DPDK init or a specific device attach.

This wasn't crucial until we refactored NVMe bdev hotplug
poller to use enumerate instead of attach, which broke the
hotplug entirely. Unluckily, the hotplug tests were broken
as well and didn't detect this in time.

We fix the above by rescanning the pci bus before iterating
through its devices inside spdk_pci_enumerate().

Change-Id: I9643514ff07883eff0f3004b6991ca43ce0b2804
Signed-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/c/438243
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-01-09 08:23:42 +00:00
..
env_internal.h env: make the generic device attach API public 2018-12-06 03:41:32 +00:00
env.c env: drop DPDK 16.07 support 2018-11-30 19:59:34 +00:00
env.mk dpdk-sub: move submodule and stop building cryptodev API in makefile 2019-01-02 13:01:34 +00:00
init.c env: add spdk_env_dpdk_post_init 2019-01-08 13:28:31 +00:00
Makefile env: add pci_virtio.c 2017-09-26 14:28:24 -04:00
memory.c memory: return first translation from mem_map_translate 2018-12-13 22:27:21 +00:00
pci_ioat.c pci: remove ioat-specific attach functions 2018-12-07 17:24:19 +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.c pci: rescan the bus on device enumeration 2019-01-09 08:23:42 +00:00
threads.c env: drop DPDK 16.07 support 2018-11-30 19:59:34 +00:00
vtophys.c env: drop DPDK 16.07 support 2018-11-30 19:59:34 +00:00