Commit Graph

5811 Commits

Author SHA1 Message Date
Ben Walker
4608e917de Update 18.07.1 Changelog
Change-Id: I527b30a852031a79a01a8ad73e63682a3076296a
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/424892
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-09-10 22:34:58 +00:00
Jim Harris
f55ffa8b57 Update DPDK submodule to 18.05.1 + SPDK patches.
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I6caea461d2b13239dee42f6f96c5b9bdde14c160

Reviewed-on: https://review.gerrithub.io/423157
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-09-10 21:16:10 +00:00
Jim Harris
f3cedcc7fe bdev: set iovs on correct bdev_io in spdk_bdev_io_put_buf
spdk_bdev_io_put_buf() is responsible for reclaiming
bdev-allocated buffers from a bdev_io.  If there are
bdev_ios waiting for one of these buffers, it calls
spdk_bdev_io_set_buf() on the next bdev_io in the queue.
This will set the iov_base and iov_len on the bdev_io
to point to the bdev-allocated buffer.

But spdk_bdev_io_put_buf() was calling spdk_bdev_io_set_buf()
on the just completed bdev_io, not the next bdev_io in the
queue.  So fix that.

Fixes: 844aedf8 ("bdev: Simplify get/set/put buf functions")
Reported-by: Alan Tu
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: Ibbcad6e35a3db6991bd7deb3516229572f021638
Reviewed-on: https://review.gerrithub.io/424881
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-09-10 21:16:10 +00:00
Jim Harris
44a43939e8 nvme: add quirk for Intel SSDs without vendor-specific log pages
QEMU emulated NVMe SSDs report themselves with an Intel vendor ID,
but don't support the Intel vendor-specific log pages.  So add
a quirk to avoid confusing error messages.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: Ic41476801ede94d43acb9972217ea7420ca53679
Reviewed-on: https://review.gerrithub.io/423422
Reviewed-on: https://review.gerrithub.io/423928
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-09-05 20:45:06 +00:00
Karol Latecki
9fca71f514 scripts/vagrant: change create_vbox.sh shebang
pushd and popd not in default path for /bin/bash

Change-Id: I83e0bd1f87005e1c8542ac3db44b26f83eedf96c
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/421903
Reviewed-on: https://review.gerrithub.io/423925
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-09-05 20:45:06 +00:00
Seth Howell
bbb2989c26 bdev: increment io_time if queue depth > 0
This value is used to calculate the disk utilization of a given bdev.

Change-Id: I4bf101c524b92bdd21573941e17f61db59c5c6b8
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/423017
Reviewed-on: https://review.gerrithub.io/423927
Reviewed-by: Seth Howell <seth.howell5141@gmail.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: Ben Walker <benjamin.walker@intel.com>
2018-09-05 20:45:06 +00:00
Dariusz Stojaczyk
4baae265ca dpdk/pci: support DPDK 18.08 write combined PCI resources
We used to support it by default in our DPDK forks,
but starting with DPDK 18.08, a new PCI driver flag
RTE_PCI_DRV_WC_ACTIVATE is required.

We enable now it for NVMe and Virtio, but not for I/OAT,
as our I/OAT driver currently assumes strong memory
ordering, which prefetchable resources do not provide.

Change-Id: I1a13356e28535981153b3d3e52bfe9d66b6172ae
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/422588
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: <wenqianx.zong@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Tested-by: Jim Harris <james.r.harris@intel.com>
2018-08-21 14:31:09 +00:00
Dariusz Stojaczyk
ec611eb485 env/dpdk: link with rte_kvargs by default
Starting with DPDK 18.08, rte_kvargs is a dependency
of rte_eal.

Change-Id: I0cde78f632fc313cec745d41ee519fb8b37de81a
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/422587
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: Jim Harris <james.r.harris@intel.com>
2018-08-21 14:31:09 +00:00
Ben Walker
716ad0e389 SPDK 18.07
Change-Id: I9b9c8f0c213dcdd4d233171daf41e96033324af6
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/421164
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-08-02 21:03:33 +00:00
Changpeng Liu
4a9ba4ef78 bdev/nvme: fix the error usage of function return value
Fix the issue #379.

Change-Id: Ia953d4ebe232d389ba3264074592ae8d0cff467a
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.gerrithub.io/421078
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: Ben Walker <benjamin.walker@intel.com>
2018-08-02 16:44:31 +00:00
Dariusz Stojaczyk
c9e5777ede virtio: clarify feature negotiation failure
Change-Id: Ifb1566033569af0b3cf4a9dfbc8094a9883c7622
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/420980
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-08-01 19:16:54 +00:00
Dariusz Stojaczyk
eeb1650c06 virtio: propagate error codes
Many functions were inconsistent in regard of error codes
they returned. In a couple of places we could print "Operation
not permitted" via strerror() from functions that were
supposed to return negative return codes, but returned
`-1` instead. (-EPERM == -1)

Change-Id: I7c36e54d449352dbd8036746e4f44a65c9b1d0b3
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/419007
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-08-01 19:16:54 +00:00
Dariusz Stojaczyk
813ed709a5 doc/vhost_processing: outline the differences between virtio and vhost
Change-Id: I205df3cb852e34e8727bbd2e6c9a3a1125c86e50
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/420800
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-08-01 19:12:09 +00:00
Maciej Szwed
83d1bfae41 nvme: Unregister NVMe controller when bdevs creation fails
This patch fixes github issue #385.
We need to unregister previously created NVMe controller
when creation of NVMe bdevs fails otherwise we won't be
able to use NVMe device as it will stay in wrong state.

Signed-off-by: Maciej Szwed <maciej.szwed@intel.com>
Change-Id: I28a165aba1a556a2ed2d4cd5ff6fd510e80657d3

Reviewed-on: https://review.gerrithub.io/421006
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: Ben Walker <benjamin.walker@intel.com>
2018-08-01 18:43:53 +00:00
Dariusz Stojaczyk
117fdae94b virtio: fix false-positive assertion failure on virtqueue_req_add_iovs
We need to decrement the free_cnt before checking
if it reached 0.

Note: the vq_free_cnt overflow is asserted at the
beginning of the function.

Change-Id: I655217785e4425d1cd3c704d24321b643be55dcf
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/420584
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-08-01 17:25:24 +00:00
Chen Wang
ea55b03940 nvme/nvme_rdma: free the ctrlr when creating the qpair fails
Release nvme rdma ctrlr before exit the nvme_rdma_ctrlr_construct function
when creating the admin qpair fails.

Fixes GitHub issue #363.

Change-Id: Ib988e0da2f627db06b68bd3fb72c117c52572cf8
Signed-off-by: Chen Wang <chenx.wang@intel.com>
Reviewed-on: https://review.gerrithub.io/420719
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-08-01 17:23:49 +00:00
Ben Walker
6779479067 nvmf: Simplify spdk_nvmf_qpair_disconnect
Asking which thread we're currently on is more expensive
than sending a message.

Change-Id: I9d9007c9f7f30e4cdd9a97de6bf7a10b0e2a0594
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/420933
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2018-08-01 17:13:48 +00:00
chenlo2x
62209642ce Autotest: revise coding-style of all script under the test/iscsi_tgt directory.
These changes were modified by the shfmt tool that supports Google's Style guide.

Change-Id: I27dd8ba91afc0043b3ce5f0eb6121a3c11789fab
Signed-off-by: chenlo2x <longx.o.chen@intel.com>
Reviewed-on: https://review.gerrithub.io/408147
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-08-01 16:42:19 +00:00
Jim Harris
cf90380720 CHANGELOG.md: remove duplicated BlobFS entry
Reported-by: Shuhei Matsumoto
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I253ad84d6705550585dcd1da48560300b0eb8377

Reviewed-on: https://review.gerrithub.io/420939
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-08-01 16:33:44 +00:00
Pawel Niedzwiecki
e7878c7cdc RPC: Fix set_bdev_nvme_options
Change-Id: I9d8853eb95834fe856d8104b61777b0373e9f347
Signed-off-by: Pawel Niedzwiecki <pawelx.niedzwiecki@intel.com>
Reviewed-on: https://review.gerrithub.io/420762
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-08-01 16:00:49 +00:00
Seth Howell
63528ebc76 bdev: Add read and write latency ticks to stats
These were left out previously.

Change-Id: I4e97068d2f13ca1dd1cfae1b25564641cee794ef
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/419601
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>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2018-07-31 23:26:07 +00:00
Seth Howell
dd9cd4352d bdev: add tracking for time spent processing I/O.
Two extra fields are added to the iostat rpc.
1. io_time. The amount of time since queue depth tracking was
enabled that has been spent on I/O processing.
2. weighted_io_time. Incremented each time this bdev's queue depth is
polled by the amount of time spent processing I/O since the last polling
event times the measured queue depth.

Change-Id: Ie70489ec24dee83f3eeac8f4f813ec7074ff458f
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/419031
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-07-31 23:26:07 +00:00
Dariusz Stojaczyk
c9f4db3027 configure: clarify RAID bdev warning msg
Change-Id: If5b6dc7651dba8e82d692cd3bc2d2e2cb09b6eb0
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/420861
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-07-31 23:16:19 +00:00
Dariusz Stojaczyk
ee5e898a86 bdev/nvme: check against strdup failure
Change-Id: I161859fafbcb5f649990641887d6edc914343946
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/420902
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-07-31 23:15:40 +00:00
Ben Walker
812a38d497 Reorganize 18.07 Changelog entries.
Fill in some missing things based on the diff

Change-Id: I5dadd6ac31dac7e9cf483c514080f88b1429a405
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/420922
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: Seth Howell <seth.howell5141@gmail.com>
2018-07-31 23:05:14 +00:00
Jim Harris
121d632c02 nvme_manage: use SCNu64 for uint64_t input
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I3e27c98a9dd72dce4fb333f04f8026392d1fcad3

Reviewed-on: https://review.gerrithub.io/420794
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-07-31 21:57:34 +00:00
Pawel Niedzwiecki
a278b14296 test/qemu: Update qemu version to spdk-2.12
Change-Id: I2784166f6b92440ab4979d4ccfd588f91252bbaa
Signed-off-by: Pawel Niedzwiecki <pawelx.niedzwiecki@intel.com>
Reviewed-on: https://review.gerrithub.io/420878
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Seth Howell <seth.howell5141@gmail.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-31 19:59:10 +00:00
Dariusz Stojaczyk
120c4f3c05 CHANGELOG: add DPDK 18.05 note
Change-Id: I17e1663ee2a231a41ca3747afe83a0a57054b8e7
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/420728
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Seth Howell <seth.howell5141@gmail.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-31 16:47:45 +00:00
Maciej Szwed
f4369b9eed nvme: fix memory leak on NVMe bdev creation failure
Signed-off-by: Maciej Szwed <maciej.szwed@intel.com>
Change-Id: If90434452dba51fbb72c8c486e3c1e4691549c34

Reviewed-on: https://review.gerrithub.io/420845
Reviewed-by: Xiaodong Liu <xiaodong.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-07-31 16:14:50 +00:00
Seth Howell
b0171f79c3 nvmf_tgt: delete connections accepted during shutdown
With the reordering of the nvmf_tgt states, we need to remove any
connections accepted during the shutdown pahse of the target.

Change-Id: I768484366da8273df74b8d52a3e8de6158b6995f
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/420681
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>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Ziye Yang <optimistyzy@gmail.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-31 16:14:29 +00:00
Seth Howell
3f6041bce4 nvmf_tgt: reverse states during shutdown
Now that the acceptor poller is also checking for asynchronous rdma
events at the transport layer, we need to make sure that this is running
until all of the poll groups are deleted.

Change-Id: I34973047fcb247b8a5a36cc7db681ab0b3cb0779
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/420680
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>
Reviewed-by: Ziye Yang <optimistyzy@gmail.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-31 16:14:29 +00:00
Seth Howell
e5a6540777 nvmf: disconnect qpairs before freeing i/o channel
Previously, qpair deletion was synchronous and handled by the
io_channel_destroy_cb for the target. However, with the new asynchronous
qpair deletion api, these qpairs need to be completely removed before we
free the i/o channel and the poll group.

Change-Id: I42c62391df62825d53e158306c4372523403ad27
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/420208
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>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-31 16:14:29 +00:00
Seth Howell
e4c1e5f866 nvmf: destroy_poll_group uses disconnect_qpair asynch api
Change-Id: I47eff0db1ab33be23881f694d104e903706f1c28
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/417371
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-31 16:14:29 +00:00
Seth Howell
f2b22d68d6 subsystem: defer channel iter until pg functions return
The poll group pause, resume, remove, and add functions are only called
from the subsystem_state_change_on_pg function. Previously, they would
return immediately and the state change would move on to the next
channel. However, some of these functions (specifically remove) kick off
asynchronous APIs and we should not iterate past them until those
asynchronous operations complete.

Change-Id: I78804273b39f2d171ba26ac4478ad515356833f3
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/419289
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-31 16:14:29 +00:00
dongx.yi
6987057f97 nvmf: update spdk_nvmf_fabric_prop_get_cmd.attrib
NVMF spec lists that the property get commnad and set command
attributes bits 7:3 is reserved, bits 2:0 is used for the size
of property to return.
So update the codes for nvmf specification compliance.

Change-Id: If41cdf2b4b1b17ea6a1c44b13dba2a361d541b48
Signed-off-by: dongx.yi <dongx.yi@intel.com>
Reviewed-on: https://review.gerrithub.io/420735
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-31 16:11:19 +00:00
Dariusz Stojaczyk
b326e51219 bdev/virtio_blk: defer bdev destruct completion
Even after the bdev is removed, the underlying virtio
device may be still alive for some time. The user may
then try to recreate the virtio bdev and could technically
initialize a second simultaneous connection to a vhost
target. It does not cause any technical problems, but the
target may reject such connection if it reached a connection
cap or doesn't support more than one connection per target
(like SPDK vhost does as of today).

Since the fix is straightforward, here it is.

Note:
Virtio SCSI is already safe, because it uses a separate
completion callback to indicate virtio device destruction.

Change-Id: I2989780ef9b13c19d0432224ff4602a14be48315
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/420576
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-07-31 01:13:07 +00:00
Ben Walker
a1ec258ac7 Clean up some incorrect Copyright statements
Daisuke Aoyama originally contributed to istgt, the
iSCSI target in FreeBSD. The SPDK iSCSI code is
originally derived from that. Due to copy and paste,
some incorrect copyright attributions have been added
to other files that do  not derive from istgt, so
this patch removes those.

It is doubtful, at this point, that there is any code
whatsoever that remains from the original istgt, but
we can revisit that at a later time.

Change-Id: I207e1e6b99d271e2f12690be90a96f7d0c113af7
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/420679
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-30 16:29:38 +00:00
Shuhei Matsumoto
e67338d464 bdev/raid: Factor out add raid bdev config operation
Change-Id: I79abce53526fa71981a969cc5599f496f4606f35
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-on: https://review.gerrithub.io/420327
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Kunal Sablok <kunal.sablok@intel.com>
2018-07-30 15:44:27 +00:00
Shuhei Matsumoto
eff04f8e4c bdev/raid: Factor out delete raid bdev config operation
Change-Id: I71f98a7cfd49f391ce9880c42f53072c6264ef1d
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-on: https://review.gerrithub.io/420326
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Kunal Sablok <kunal.sablok@intel.com>
2018-07-30 15:44:27 +00:00
Shuhei Matsumoto
e923c66a07 bdev/raid: Free all strings allocated by JSON decoder on all paths in RPC
Use strdup for all strings allocated by JSON decoder and free them on
all paths.

Change-Id: Ia30d32c2fd6bd79f62588ca19bd3bb093d38a502
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-on: https://review.gerrithub.io/420325
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Kunal Sablok <kunal.sablok@intel.com>
2018-07-30 15:44:27 +00:00
Shuhei Matsumoto
90f54670bc bdev/raid: Use TAILQ to manage RAID bdev configuration
Change-Id: I971df38c577284916212e58b77c73499127a980a
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-on: https://review.gerrithub.io/420217
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-07-30 15:44:27 +00:00
Shuhei Matsumoto
32cc0199d1 bdev/raid: Use single character variables to index and loop iterator
Change-Id: I1023a509f938fcbe6ac0c35dca5192c36990de91
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-on: https://review.gerrithub.io/420216
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Kunal Sablok <kunal.sablok@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-07-30 15:44:27 +00:00
Maciej Szwed
8cdff7ed79 doc: fix example for construct_nvmf_subsystem method
Signed-off-by: Maciej Szwed <maciej.szwed@intel.com>
Change-Id: Id2982f649c879bc69023da928bb2219f0cd8d85c

Reviewed-on: https://review.gerrithub.io/420748
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Piotr Pelpliński <piotr.pelplinski@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-07-30 15:40:15 +00:00
Dariusz Stojaczyk
47f1db1344 bdev/null: free global resources on module finish
Also, don't try to remove any bdevs. The bdev layer
does that before module fini is even started.

Change-Id: I869f4b9e6d8590bfae2504a96d971c4f8866aeb9
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/420577
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-07-30 15:38:07 +00:00
Jim Harris
ecb44872b6 test: add some basic raid tests
RAID is experimental for 18.07, pending iov support
which is needed for vhost.  But we need to at least
build RAID in our tests, and run some basic
bdev tests to ensure it doesn't quickly become stale.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I68bb45df6d00e31dc96ed8bc902b61a5ef699ba2

Reviewed-on: https://review.gerrithub.io/420678
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-30 14:59:45 +00:00
Jim Harris
c60ae3c356 raid: get buffer on reads before sending child ios
For front-ends like iSCSI (and NVMe-oF in the future)
which want the backend to specify the data buffer, the
RAID module doesn't copy the pointer to the allocated
buffer from the child IO back to the parent IO.  It
really can't copy the pointer - the child IO owns it
and will free it.

So the RAID module needs to allocate the buffer first
and then pass it down.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I3b1eceac9b1cdd26130e59e1d400c9869a19f881

Reviewed-on: https://review.gerrithub.io/420677
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-30 14:59:45 +00:00
Jim Harris
cabe0203da raid: break out read/write code into separate function
This is needed for next patch which needs to defer reads
when getting an io buf.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: If31e7d76384c7fd05cc77a3b2124ee4e9354823e

Reviewed-on: https://review.gerrithub.io/420676
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-07-30 14:59:45 +00:00
Xiaodong Liu
9928e9d98a ocssd: apply ocssd strings into status arrays
Change-Id: If25463ea76e8382c61f10636e1119376a00104dc
Signed-off-by: Xiaodong Liu <xiaodong.liu@intel.com>
Reviewed-on: https://review.gerrithub.io/411594
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: Changpeng Liu <changpeng.liu@intel.com>
2018-07-30 03:09:31 +00:00
Xiaodong Liu
d4a5ef7eab ocssd: print ocssd chunk info in identify app
Get Log Page - Chunk Information could return info
of all chunks. In order to have a glance of them,
by default, get information of 8 chunks starting
from the first chunk.

Change-Id: I7c395f631a3e7f02d59ad6758b347e249baa9c3d
Signed-off-by: Xiaodong Liu <xiaodong.liu@intel.com>
Reviewed-on: https://review.gerrithub.io/411593
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-07-30 03:08:21 +00:00
Xiaodong Liu
ade59b217b ocssd: print ocssd features in identify app
Change-Id: Id79793e375e0f1dc2690869c4c38f59209cf806b
Signed-off-by: Xiaodong Liu <xiaodong.liu@intel.com>
Reviewed-on: https://review.gerrithub.io/411592
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2018-07-30 03:06:17 +00:00