Commit Graph

9721 Commits

Author SHA1 Message Date
Maciej Wawryk
a1bda4e1aa RPC: rename construct_split_vbdev to bdev_split_create
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: I37459e3c421e8c657f8d9a8647cdbccc4193bb58
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468089
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-09-19 19:24:47 +00:00
Seth Howell
72d06a99e1 Revert "iscsi: change the field bhs to pointer type."
This reverts commit 80cf038ced.

Signed-off-by: Seth Howell <seth.howell@intel.com>
Change-Id: I95e2ddfbc9cd07e874a385b345dc401fc8076e88
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468778
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>
2019-09-19 05:04:00 +00:00
Seth Howell
a19e674be0 make: always fail if mk/config.mk doesn't exist.
We previously were failing for all make targets except for clean if the
mk/config.mk file didn't exist, but we should also be failing to
perform make clean if we don't have this file. It turns out you end up
erroring out in the next line anyways. Also, if you make that include
optional, make still fails because we don't have any kind of environment
specified and spdk.common.mk depends on that variable being defined.

There may be some benefit to being able to run make clean if we don't
have a valid configuration file, but right now, there are a lot of
things that depend on the configuration file, such as which environment
file to make or clean and which directories need cleaned.

Change-Id: I2a9c1e982c01ba76b67b153ee7336402300b76b0
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/466346
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-09-19 05:03:49 +00:00
Mike Carlin
390542a39e spdkcli: Add support for TCP connection
Adds an option to spdkcli.py to allow connection over a tcp
via a host address and port. These options match the format
that exists in rpc.py

Signed-off-by: Mike Carlin <mikefcarlin@protonmail.com>
Change-Id: I7e9e1c376546dd765ffd6f4f4db88e193e9aa0ef
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467844
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>
2019-09-19 05:03:09 +00:00
Shuhei Matsumoto
f66aea7fc3 bdevperf: Use zcopy APIs for simple write I/O case
Add a bdev_io pointer to struct bdevperf_task.

In bdevperf_zcopy_get_buf_complete() which is the callback to
spdk_bdev_zcopy_start(), bdev_io is saved into the current task.

Then bdevperf_submit_task() will call spdk_bdev_zcopy_end()
by using the saved bdev_io.

Besides, when spdk_bdev_zcopy_start() is called with populate=false,
increment target->current_queue_depth when it completes successfully,
and do not increment target->current_queue_depth when the corresponding
spdk_bdev_zcopy_end() is called with commit=true.

The reason is that IO processing is already started when
spdk_bdev_zcopy_start() is called.

The next patch will use zcopy APIs for write I/O with verify or
reset cases.

Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I12f3b1ccac726abe345a64f06e33d65d2a3538fd
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467900
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2019-09-19 04:40:57 +00:00
Pawel Kaminski
7e875f371f rpc: Rename passthru related rpcs.
Rename construct_passthru_bdev to bdev_passthru_create
Rename delete_passthru_bdev to bdev_passthru_delete

Change-Id: I8850b78f846acc42cb8530acaf462af867b0bb2e
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/466520
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-09-19 04:17:54 +00:00
Konrad Sztyber
29a9a3089a test/ftl: remove SPDK_TEST_BDEV_FTL
There were two variables controlling libftl's tests.  Only one of them
is actually needed (SPDK_TEST_FTL), so this patch removes the redundant
one.

Fixes #956

Change-Id: I125b9cb7d855351488b445da165be9e27f10f914
Signed-off-by: Konrad Sztyber <konrad.sztyber@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467932
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: yidong0635 <dongx.yi@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-09-19 04:15:42 +00:00
paul luse
42c79b072f module/raid: move struct defn from C to H file
In prep for using it as part of a func pointer delcaration in
an upcoming patch.

Change-Id: I3272c4e0f16a894b52a0601323c7d9148592ca3f
Signed-off-by: paul luse <paul.e.luse@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467698
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>
2019-09-19 04:02:16 +00:00
paul luse
84bd67048f module/raid: move struct definition up
In prep for upcoming patch that needs it declared earlier.

Change-Id: Ia618d95108c0ab5e71618470ac36f822a9aa0129
Signed-off-by: paul luse <paul.e.luse@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467552
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: Maciej Szwed <maciej.szwed@intel.com>
2019-09-19 04:02:16 +00:00
yidong0635
024127dcfd rdma: Add return value check for memory map notify.
Now code always return 0 , do this like nvme_rdma_mr_map_notify.
That callback can get the right return.

Change-Id: Ief2924e14321b2062f6001e7ae3f50d507206594
Signed-off-by: yidong0635 <dongx.yi@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468663
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: Changpeng Liu <changpeng.liu@intel.com>
2019-09-19 01:55:55 +00:00
JinYu
d81721df65 vhost: fix the reuse of free memory issue in scsi
In the spdk_vhost_scsi_dev_remove() it takes a period of time
to remove all the tgts but before it is completed the scsi dev
has been freed. So don't free the scsi dev until all the tgts
have been removed.

Fix Github issue #932

Change-Id: Idf9293c70b8d5f82091db6dd5e018a5cb40eea36
Signed-off-by: JinYu <jin.yu@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/464654
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>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
2019-09-19 01:34:07 +00:00
paul luse
b28aa25e61 ut/compress: remove extra success test case
By moving the success test case to the end we avoid the scan-build
issue however the last test case was already testing success so just
udpated the comment and free the memory at the end.

Fixes issue #933

Change-Id: I0ca81f240d3af32c414b0c886fda5b14ba37e490
Signed-off-by: paul luse <paul.e.luse@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467302
Reviewed-by: yidong0635 <dongx.yi@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-09-19 01:06:31 +00:00
Karol Latecki
03578a3d25 scripts/vm_setup: add Arch Linux test dependencies install
Dependencies install with -i option works OK.

Additional dependencies with -t option:
- rocksdb - OK
- librxe - OK
- iscsi - OK
- ocf - OK
- flamegraph - OK
- tsocks - OK
- nvmecli - OK
- fio - compilation errors on version 3.3
	OK if updated to 3.15
- qemu - OK, but need to disable some error warnings:
	-Wno-error=stringop-truncation
	-Wno-error=deprecated-declarations
	-Wno-error=incompatible-pointer-types
	-Wno-error=format-truncation
- qat - not run
- vpp - not run
- libiscsi - compilation errors

Change-Id: Ifde26c1f1d35c8fe06e18ddba33fe2d054b6d2cf
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/466948
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Seth Howell <seth.howell@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-09-18 22:25:18 +00:00
Seth Howell
579d44b0ee nvme_rdma: make handling of cm_events more robust
By splitting all cm_event handling into a single function, we can create
a single point of contact for cm_events, whether we want to process them
synchronously or asynchronously.

Change-Id: I053a850358605115362f424de55e66806a769320
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467546
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>
2019-09-18 22:19:37 +00:00
Seth Howell
ad7a01bde3 nvme_rdma: make cm_event fd asynchronous.
This is paving the way for additional changes to enable polling for
cm_events in the initiator.

For now, just present the same blocking API on top of the now polled
file descriptor. Later, we will change this API to be more useful.

Change-Id: I174dac028720f95c30100f6dc2ed49b5bb2a7e40
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467545
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>
2019-09-18 22:19:37 +00:00
Pawel Kaminski
f54df84058 rpc: Rename construct_nvme_bdev to bdev_nvme_attach_controller
Change-Id: I1831eb39d3d357594968271b2ee69bb48502a59c
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/466138
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Broadcom SPDK FC-NVMe CI <spdk-ci.pdl@broadcom.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>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2019-09-18 21:53:25 +00:00
Ben Walker
714a56466a test/nvmf: allow running as unprivileged user
Add a new test flag SPDK_RUN_NON_ROOT forcing some of the
SPDK applications to run as an unprivileged user. For now
we implement it in nvmf tests. If enabled, nvmf_tgt will
run as the user who invoked `sudo ./autotest.sh`.

Running SPDK as non-root has two major prerequisites right now:
 * there must be an IOMMU in the system in order to use PCI devices
 * DPDK version must be either < 18.05 or >= 19.08-rc1

Change-Id: If1ba9dfcc09fc6cac059867408a1b54eddecfb4b
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Signed-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/454679
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-09-18 20:34:39 +00:00
Darek Stojaczyk
c049304a95 env: add spdk_pci_device_unclaim()
spdk_pci_device_claim() could create a file on the
filesystem that couldn't be deleted programatically.
It could only be overwritten - e.g. by another spdk
instance - but this didn't really work if that
another instance had less privileges and hence no
access to the previous file.

This is exactly the case we're seeing on our CI when
running SPDK as non-root. In general it's a good idea
not to leave any leftover files, so now we'll delete
the pci claim file when the spdk process exits.

spdk_pci_device_claim() used to return a file descriptor
that could be simply closed to "un-claim" the device.
It'll now return only a return code. The fd will be
stored inside spdk_pci_device and will be closed either
when user calls the newly introduced spdk_pci_device_unclaim(),
or when the device is detached.

We'll still need to clean up those files somewhere in
our test scripts (probably ./setup.sh cleanup) to
clean up after crashed processes or so - but we don't
necessarily want to run such scripts inside the autotest
whenever a non-root spdk is about to be started.

Change-Id: I797e079417bb56491013cc5b92f0f0d14f451d18
Signed-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467107
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>
2019-09-18 20:34:39 +00:00
Pawel Kaminski
38d4a2a2f2 test: Shellcheck - apply rule SC2209
Use var=$(command) to assign output (or quote to assign string).

Change-Id: I4067db46697c32f24e0b4df7d573929ee75757a7
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467291
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-09-18 20:21:13 +00:00
Pawel Kaminski
ee3403b5ee scripts/rpc: Rename rpcs related to ftl bdev
Rename construct_ftl_bdev to bdev_ftl_create
Rename delete_ftl_bdev to bdev_ftl_delete

Change-Id: I661ecea2ed5f53880c9a77819fcca064f0410535
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/465897
Reviewed-by: Broadcom SPDK FC-NVMe CI <spdk-ci.pdl@broadcom.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-09-18 20:20:15 +00:00
paul luse
149f0f7eb4 module/compress: fix a few typos in comments/log messages
Signed-off-by: paul luse <paul.e.luse@intel.com>
Change-Id: I44046184cfc99f5307d686c4f66704b43d2ba5fc
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468169
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>
2019-09-18 18:17:28 +00:00
Ziye Yang
80cf038ced iscsi: change the field bhs to pointer type.
Purpose: Prepare for the further optimization work
to use one bigger buffer to read more data for
reducing system calls.

Signed-off-by: Ziye Yang <ziye.yang@intel.com>
Change-Id: Ie92603b09308bd3149263269fdec355b67251b37
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468538
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-09-18 18:14:53 +00:00
Pawel Kaminski
655b64da52 rpc: Rename delete_pg_ig_maps to iscsi_target_node_remove_pg_ig_maps
Change-Id: I9e704d5fbc68afb006cde0f33d9b9b4c71b18a8a
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467342
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-09-18 18:09:13 +00:00
Pawel Kaminski
a1c9546f1a rpc: Rename add_pg_ig_maps to iscsi_target_node_add_pg_ig_maps
Change-Id: Ie738991ef27f836a0027e64281cbda1599439240
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467605
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: Paul Luse <paul.e.luse@intel.com>
2019-09-18 18:09:13 +00:00
Ben Walker
8fb1cf2f18 test/vhost: Remove event function stubs
These aren't used anymore.

Change-Id: I91400f1ad8a620d84f1b7478ffa551bb1755d233
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468505
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>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2019-09-18 16:45:05 +00:00
Ben Walker
28a0aac40c test/nvmf: Remove event function stubs
These were removed from the nvmf target, so the stubs aren't
needed.

Change-Id: I77b783019ee842c15d92b89cdffcb342b10d92c6
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468504
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Seth Howell <seth.howell@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2019-09-18 16:45:05 +00:00
Ben Walker
91eb55fc0a test/iscsi: Remove stubs for event calls
The calls were removed from the code, so we don't need
the stubs anymore.

Change-Id: Ie3616d186ab172c3b7a6223b4ff754308fad9dc0
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468503
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>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2019-09-18 16:45:05 +00:00
Ben Walker
f23e89c58e test/bdev: Use thread library in bdevio
No longer use the event system.

Change-Id: Ib75d17e481f3421859142a4cee4b5881570e8582
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468388
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>
2019-09-18 16:45:05 +00:00
Ben Walker
7f9c41bee0 event: Repack struct spdk_reactor
Get all of the important stuff into the first cache line.

Change-Id: I5bbfb031bb1d693019abb9e5145579d0b867eaf5
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/465994
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>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2019-09-18 16:45:05 +00:00
Xiaodong Liu
3cba062b86 blob_bdev: add spdk_bdev_create_bs_dev_from_desc
New interface for create spdk_bs_dev from bdev desc.
This change, together with spdk_bdev_open_ext, can
remove the race condition where user gets the bdev
structure, but bdev is removed after getting that
structure and before spdk_bdev_create_bs_dev function
is called.

Change-Id: Ia80c3527ff91b45f97f44d295a5cb6d83f5ee0e4
Signed-off-by: Xiaodong Liu <xiaodong.liu@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468412
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2019-09-18 02:59:59 +00:00
Pawel Kaminski
032a8b1c9b rpc: Rename set_iscsi_target_node_auth to iscsi_target_node_set_auth
Change-Id: Iab107a8ebc92deb20dd7ae3aed9e7a12bdf87d43
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467938
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-09-17 19:54:02 +00:00
Pawel Kaminski
80494e3f23 Rename target_node_add_lun to iscsi_target_node_add_lun
Change-Id: I2f8e453973b8314eab76e59e816f3dd630b75b3c
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467936
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-09-17 19:54:02 +00:00
Pawel Kaminski
6d77994169 rpc: Rename get_iscsi_connections to iscsi_get_connections
Change-Id: Iffdf67005c14551f1aaa03e58e6773d298cc604b
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467927
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-09-17 19:54:02 +00:00
Benjamin Saunders
7188bb994f nvme: fix missing memory barrier in shadow doorbell update
If the CPU reorders the eventidx read before the shadow doorbell
write, it is indeterminate whether the controller will read the
updated shadow doorbell without an MMIO write. See
https://lkml.org/lkml/2018/8/14/1031 for details.

Signed-off-by: Benjamin Saunders <bsaunders@google.com>
Change-Id: I5aa08fdd5b32c7b81e8048ca6efe546318d80b5c
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468188
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-09-17 19:44:20 +00:00
Seth Howell
8126509c4f rdma: replace improperly aligned buffers in requests.
It is a very rare thing for a buffer to be split over two memory
regions. In fact, it is only possible in dpdk versions where
--match-allocations is not passed as a startup parameter to dpdk but
dynamic memory allocation is enabled.

By adding a small helper function, we avoid failing an I/O because it
was assigned one of these improperly aligned buffers. Also, we try to
remove the buffer from circulation so that it doesn't get picked up
again by another request.

Also, add a unit test to catch this case.

Change-Id: Ia09865c2f77160a960571665b29c4533b11758ae
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467446
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: Paul Luse <paul.e.luse@intel.com>
2019-09-17 19:43:01 +00:00
Seth Howell
98233769f4 rdma: simplify nvmf_rdma_fill_buffers
Just cleaning up a few things like variable names and ordering to make
the whole function more readable.

Change-Id: I1503cdb43ddd73e063d6e57e9ff0cf2a06e79728
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467445
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Alexey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2019-09-17 19:43:01 +00:00
Shuhei Matsumoto
8253ed5e31 nvme/perf: Fix the wrong block size when metadata size is 8 bytes and PRACT is set
When PRACT is set, if metadata size is 8 bytes, PI is stripped
(read) or inserted (write). Hence block size must not include
metadata size for extended LBA payload. This patch fixes the issue
by reducing metadata size from block size for this case.

On the other hand, When PRACT is set, if metadata size is larger
than 8 bytes, PI is passed (read) or replaced (write). So block
size is not necessary to change for this case.

The wrong block size didn't cause any visible issue but should be fixed.

Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I3351e3e3b7816f726752e85604cf557251d9870c
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468018
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-09-17 19:41:32 +00:00
Shuhei Matsumoto
062a5503ae nvme/perf: Use g_metacfg_pract_flag to bring PRACT setting
g_metacfg_prchk_flags had been used to pring PRACT setting. This
didn't cause any issue but will lead to misread.

Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I2f6c48b12ffa511afa2663d31dc9467cec980c9c
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468017
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-09-17 19:41:32 +00:00
Shuhei Matsumoto
a766dd00f4 nvme/fio_plugin: Fix the issue that PRACT doesn't work when metadata size is 8 bytes
When PRACT is set, if metadata size is 8 bytes, PI is stripped
(read) or inserted (write). Hence block size must not include
metadata size for extended LBA payload. This patch fixes the issue
by reducing metadata size from block size for this case.

On the other hand, When PRACT is set, if metadata size is larger
than 8 bytes, PI is passed (read) or replaced (write). So block
size is not necessary to change for this case.

Signed-off-by: James Bergsten <jamesx.bergsten@intel.com>
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I930c8a07519a4742c44240801b068fac2c4802a7
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/465708
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-09-17 19:41:32 +00:00
Wojciech Malikowski
a0d31fe5fa lib/ftl: Remove not needed header from ftl_init.c
Change-Id: I23fcec7a3aef7b50105bbfd63be8ee93b551ed5f
Signed-off-by: Wojciech Malikowski <wojciech.malikowski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/467369
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-09-17 19:35:45 +00:00
Kay Bouché
327f1dc4ca scripts/pkgdep.sh: Added Archlinux
Add SPDK dependency installation instructions for ArchLinux OS.

When possible dependencies are installed directly via pacman
package manager. If not available - use AUR and makepkg.

One exception is pmem dependency which is installed using
Github sources, as it seems that AUR repo is not frequently
update.
Additionally for pmem installation ldconfig needs to be
updated manually, otherwise it will break fio installation
(if done with vm_setup.sh) which detects pmdk headers, but
cannot find libraries on runtime.

Change-Id: Ib9045ba55b10c2b671e01b48dda8ec439899bc06
Signed-off-by: Kay Bouché <kay-b@live.de>
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/433913
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-09-17 18:35:06 +00:00
Karol
6df5fbfb62 scripts/vagrant: add arch-linux option
Add Arch Linux option to our Vagrant scripts.
We will probably need this for nightly tests against
latest versions of software we depend on.

Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Change-Id: I2dd1d69cbb286625343fd5e70ace0d8da1218825
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/466832
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Seth Howell <seth.howell@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Reviewed-by: Maciej Szwed <maciej.szwed@intel.com>
2019-09-17 18:35:06 +00:00
Maciej Wawryk
391503d799 scripts/vagrant: allow using custom emulator
We want to use Vagrant scripts in our CI.
It will allow us to remove statically configured
virtual machines and spawn new instances dynamically.

This patch allows us to use custom version of emulator
instead of preinstalled on host.

Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: Iff79cd28d4d5b21fcf327db455ef060182f0f4ef
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/465925
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
2019-09-17 18:32:06 +00:00
Karol Latecki
1e91f5bd56 test/vhost: move migration tests to RUN_NIGHTLY
Test scripts are no longer failing and can be
re-enabled in nightly testing.

Change-Id: I07e682466f98a63c65b1d17cca47a4136809e8c9
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468203
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-09-17 18:31:11 +00:00
Karol Latecki
a2ab5eb0c6 test/vhost: respect additional params for vhost_run
Removing "shift" command because it was not needed and
caused vhost run command to be not properly constructed.

Needed to fix if contition for --no-pci param while at it.
There was no $no_pci variable defined after optargs were
removed.

Change-Id: I72c615fdb2a5fd507efedae100b9b79c5cfd8935
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468202
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-09-17 18:31:11 +00:00
Karol Latecki
1b10706ee0 test/vhost: remove hardcoded vhost name id
This line called vhost_kill with 2 arguments:
$1 - string "0"
$2 - string "vhost_name"

Problem was that vhost_kill only accepts 1 argument, which
is "vhost_name". This was not noticed because in seems in
most of our tests we just use the name "0".
This would fail to kill a vhost instance in case it would
be named anything else than "0"

Change-Id: I635c5b92673abb7350d8bd6c636f6b794651f7ac
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468201
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-09-17 18:31:11 +00:00
Shuhei Matsumoto
cc539da903 nvme/fio_plugin: Fix the issue that PRACT is not set in NVMe command
If PRACT is enabled, DIF context was not initialized. However it was
expected that PRACT is passed through DIF flags of the DIF context.
Hence PRACT was not set in NVMe command even if user set PRACT.

This patch fixes the issue by passing fio_qpair->io_flags instead
of dif_ctx->dif_flags.

Signed-off-by: James Bergsten <jamesx.bergsten@intel.com>
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: Ibcb74fc8f74f863d8b53d53484fdea66f4b5db8e
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468016
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: James Bergsten <jrb@thebergstens.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-09-16 05:28:10 +00:00
Shuhei Matsumoto
e97148d5dd nvme/fio_plugin: Fix the issue that DIF context is initialized only for write I/O
DIF context has to be initialized both for read and write I/O. However,
it had been initialized only for write I/O unintentionally after
refining error processing.

This patch fixes the issue.

Signed-off-by: James Bergsten <jamesx.bergsten@intel.com>
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I363da40ddba186e52fd0dfce37cfb0dea325040d
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468015
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: James Bergsten <jrb@thebergstens.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-09-16 05:28:10 +00:00
Maciej Wawryk
11f6b77370 RPC: rename get_bdev_histogram to bdev_get_histogram
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: I2cc4d0a39d508e87608f4181ff8bf1b6bd12d839
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468087
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-09-13 22:39:15 +00:00
Maciej Wawryk
ab6ce82806 RPC: rename enable_bdev_histogram to bdev_enable_histogram
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: Ie60cf733138c677af71db66d24880af33b099673
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/468085
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-09-13 22:39:15 +00:00