Spdk/lib
Darek Stojaczyk 3c722d6fae pci: allow devices to be attached by surprise
With all the error checks and segfault preventions in place,
we can finally enable hotplug in a multi-process scenario
for DPDK 18.11+.

If a device is attached in the primary process, it will send
an attach IPC request to the secondary process which needs
to succeed. Until now it would get rejected, and the attach
would fail in all the processes.

The device in secondary process will be now probed by DPDK
and will be put into the process local SPDK list of devices
to be locally attached. Either SPDK will attach it sometime
later on any attach/enumerate request, or DPDK will remove
it automatically once the same device in the primary process
gets removed.

We also allow the surprise attach in primary processes, as
it's technically possible for the pci devices (NVMe) to
be attached exclusively from the secondary process. The
fact that the NVMe stack doesn't support it is another story.
Currently the NVMe stack will handle the failure by itself
just fine.

Change-Id: Ia24a8b4610cc7c659f59a2fdda9d8a78e58af873
Signed-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/434416
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-12-04 15:41:21 +00:00
..
bdev bdev/nvme: forbid attaching two controllers with the same name 2018-12-03 19:52:26 +00:00
blob log: remove "trace" from internal API 2018-12-03 19:50:15 +00:00
blobfs log: remove "trace" from internal API 2018-12-03 19:50:15 +00:00
conf conf: don't strdup name if section already exist 2018-05-17 17:13:19 +00:00
copy lib/copy: unregister copy engine on finish 2018-10-15 17:42:20 +00:00
env_dpdk pci: allow devices to be attached by surprise 2018-12-04 15:41:21 +00:00
event app: rename traceflag cmdline option to logflag 2018-12-03 19:50:15 +00:00
ioat ioat: change the return type of ioat_channel_destruct() to be void 2018-09-18 22:41:00 +00:00
iscsi log: remove "trace" from internal API 2018-12-03 19:50:15 +00:00
json json: Use not C++ style comments // but C-style comments /* */ 2018-10-31 22:01:47 +00:00
jsonrpc jsonrpc client: move around functions so no forwad declaration is needed 2018-11-19 20:30:03 +00:00
log app: rename traceflag cmdline option to logflag 2018-12-03 19:50:15 +00:00
lvol lvol: check spdk_lvol for NULL before dereferencing it 2018-11-20 15:01:57 +00:00
nbd nbd: fixup return codes 2018-11-28 22:55:09 +00:00
net lib: fix typos in the lib directory 2018-08-24 17:15:12 +00:00
nvme nvme_tcp: correctly support the incapsule data size. 2018-12-03 22:05:29 +00:00
nvmf nvmf/tcp: add an assert for transport destroy. 2018-12-04 01:56:39 +00:00
reduce reduce: add _reduce_persist() 2018-12-03 20:34:11 +00:00
rocksdb build: remove xx_MODULES_LINKER_ARGS and xx_MODULES_FILES 2018-11-28 16:43:01 +00:00
rpc rpc: add function to get the current RPC state 2018-11-08 23:04:50 +00:00
scsi log: remove "trace" from internal API 2018-12-03 19:50:15 +00:00
sock net: add asynchronous initialization and finish 2018-11-07 17:08:27 +00:00
thread lib/thread: check for NULL return on _get_thread() 2018-11-20 15:03:17 +00:00
trace lib/trace: show specific usage of trace mask 2018-11-30 14:52:28 +00:00
ut_mock ut_mock: rename library from spdk_mock to ut_mock 2018-11-20 14:57:57 +00:00
util util: make spdk_parse_ip_addr return -EINVAL instead -1 2018-10-12 23:34:27 +00:00
vhost log: remove "trace" from internal API 2018-12-03 19:50:15 +00:00
virtio virtio: support dynamic memory registrations 2018-10-23 18:02:12 +00:00
Makefile reduce: add configure option 2018-11-08 00:01:47 +00:00