Commit Graph

18835 Commits

Author SHA1 Message Date
paul luse
efa33b8590 lib/accel: add RPC to enable override of opcode to engine
Docs explaining how to use the RPC are in the next patch in the
series.

Signed-off-by: paul luse <paul.e.luse@intel.com>
Change-Id: I7dab8fdbeb90cdfde8b3e916ed6d19930ad36e66
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12848
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2022-08-10 07:25:29 +00:00
Michal Berger
ab356d4079 test/setup: Remove the hp_status() test
This just verifies a modest setup.sh's output which is of little
relevance. On top of that, depending on the system's state, the
test itself may be flaky so get rid of it.

Signed-off-by: Michal Berger <michal.berger@intel.com>
Change-Id: Icc918a0dbbb54067c281aa465a097c4e40a32e11
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13827
Reviewed-by: Pawel Piatek <pawelx.piatek@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-09 14:38:30 +00:00
Michal Berger
327f69ea41 test/setup: Account for reserved and surplus hugepages
In some occasions the total number of available hugepages increases
by the account of reserved and/or surplus hugepages allocated by the
kernel. This affects the test where it ends up with bigger number of
hugepages then actually requested via setup.sh.

Hugepages overcommitting is disabled under CI nodes, however, this
issue spontaneously appears regardless. To rectify, add the extra
hugepages while checking the expected number + some debug to see the
state of meminfo in case the test still fails.

Signed-off-by: Michal Berger <michal.berger@intel.com>
Change-Id: If30a422240045ac188a9175eeab7210351eb34a6
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13826
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2022-08-09 14:38:30 +00:00
Shuhei Matsumoto
1bfe8f98a1 test/nvmf_timeout: Reduce TCP Ack timeout
By the default value, timeout might be too long to detect connection
failure by the end of the test. 512 milliseconds is too small to use
in production but is not so small for this case.

Fixes #2595

Signed-off-by: Shuhei Matsumoto <smatsumoto@nvidia.com>
Change-Id: I9f1248b2812eb7625aa943878b022f0a151d4cbb
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13908
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Michal Berger <michal.berger@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-09 11:51:46 +00:00
Michal Berger
5ba8b04fb9 test/nvmf: Don't redeclare trap inside nvmf_timeout test
It's not needed. $bdevperf_pid is expanded when the trap is signalled,
hence it will always hold PID of the last value it got assigned to.

Signed-off-by: Michal Berger <michal.berger@intel.com>
Change-Id: I89083667e0be5f3f0b0fd1745bfbfb38cb340c42
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13922
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-09 11:49:06 +00:00
Michal Berger
2eb37d32cd test/nvmf: Remove try.txt from nvmf_timeout test
The contents of this file is not evaluated in any way, the test only
reads it back to stdout at different stages. Instead, just keep
bdevperf writing to std{out,err}.

Signed-off-by: Michal Berger <michal.berger@intel.com>
Change-Id: Ibd0caa101e895661224f8a969395eb018ece19dc
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13921
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-09 11:49:06 +00:00
王亚飞/Yafei WANG
6fcd7a79e9 lib/vhost: Add submit_inflight_desc() to cpu usage statistic
submit_inflight_desc() actually do some meaningful work, so when it really process tasks, the poller should return BUSY status.

Signed-off-by: YafeiWangAlice <yafei.wang@samsung.com>
Change-Id: I2103cea6d28e8b355dad4ddd603d917f10e44c08
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13486
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: GangCao <gang.cao@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-09 11:48:51 +00:00
Michal Berger
bf93cbdfc5 test/vhost: Simplify disk image check for virtio
Signed-off-by: Michal Berger <michal.berger@intel.com>
Change-Id: I23b206b026dec0cb9e91226aa2ee2de91eebde6e
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13904
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-09 08:27:31 +00:00
Michal Berger
87c8a57e6f test/sma: Add missing --os param to vm_setup() call
Signed-off-by: Michal Berger <michal.berger@intel.com>
Change-Id: I0a9cd41f754f2d52a8caa936a7a7504b0091790d
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13903
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-09 08:27:31 +00:00
Jim Harris
d33497d3f4 thread: defer unregistration when for_each ops exist
There may be for_each operations outstanding on an
io_device when it is unregistered.  Currently we just
return when this happens, not unregistering the
device but also not notifying the caller that this
happened (since it returns void, and the callback
function doesn't have a status parameter either).

We could just push this responsibility to the caller,
to never unregister an io_device if it knows it has
outstanding for_each calls waiting to complete.  But
I think we can simplify this a lot by just handling
this inside of the thread library.  Mark that the
device is pending registration, and unregister it
(on the original requesting thread!) when the
for_each count gets back to zero.  Also don't
allow any new for_each operations either.

Note this requires a bit of refactoring on the
thread unit tests, since it is now possible to
unregister a device with outstanding for_each
operations.

Fixes issue #2631.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I978f2d99a25e65d2b7d71ce9b1926a79a6c94263
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13890
Community-CI: Mellanox Build Bot
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-09 08:27:15 +00:00
Jim Harris
821e673c1d thread: set non-zero status when spdk_for_each_channel fails
If spdk_for_each_channel is called on a device that doesn't
exist, we need to set a non-zero status (-ENODEV in this
case) to the completion function.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I898ad5ea499fb6087338b621b2befcadd6a05414
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13889
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Mellanox Build Bot
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-09 08:27:15 +00:00
Michal Berger
6abaf4fc64 test/vfio: Add override switch for selecting vfio-qemu bin
This would allow for better control through the environment which
could be used by the CI.

Signed-off-by: Michal Berger <michal.berger@intel.com>
Change-Id: Iaf94c82ccd7ce6851abb1ad4b7ebf76d686e3608
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13898
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-09 08:26:45 +00:00
YafeiWangAlice
d89e62e7ef spdk_top: In CORES tab, spdk_top can't collect the right poller count under certain conditions.
spdk_top can't collect the right poller count when thread count is more than core count. Max index of g_threads_info[] should be thread count NOT cores count.

Signed-off-by: YafeiWangAlice <yafei.wang@samsung.com>
Change-Id: Iff95fb1aa7f84626a559741ad135a2cbeed04f90
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13574
Community-CI: Mellanox Build Bot
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
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>
Reviewed-by: Krzysztof Karas <krzysztof.karas@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-09 08:26:05 +00:00
yidong0635
62378c24be test/reset: Remove unused usage.
Here "-m " is not used or related.

so remove it.

Signed-off-by: yidong0635 <dongx.yi@intel.com>
Change-Id: Ic8700bd0a262bb70b6116bbee86330eece5c03b0
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13879
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-08 13:48:49 +00:00
GangCao
0c980660b6 FTL: move assert earlier before accessing the field
Fix Klockwork issue.

Change-Id: Iae9557c152a745549c8963f4f0510ae829f871a4
Signed-off-by: GangCao <gang.cao@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13860
Community-CI: Mellanox Build Bot
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-08 13:48:28 +00:00
Michal Berger
4070c65d9b test/vfio_user: Update QEMU_BIN to use vfio-user-dbfix
This follows e380263ba1 - all CI nodes have been updated to an image
which ships with that particular version of vfio-user QEMU.

Signed-off-by: Michal Berger <michal.berger@intel.com>
Change-Id: I2029f48014868366881790a4e258190e3f83b0d0
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13894
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: GangCao <gang.cao@intel.com>
Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-08 10:15:57 +00:00
Jim Harris
813b92af44 setup.sh: add some more app names to the shm cleanup list
accel_perf and bdev_svc were not on the list.

Fixes issue #2483.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I9f758c1871f42c10e2c92b2fb6cd676830a1b3a0
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13877
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Michal Berger <michal.berger@intel.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-05 10:48:42 +00:00
Jim Harris
5d651b31c9 event: require opts->name is set
This has been implicitly required before, and all
in-tree apps (except accel_perf) set it, so let's
explicitly require it.  This name gets used for
things like the shm name for spdk trace event file.

While here, add the name for accel_perf.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I47a22466550d4b31bacafee58d30339b4f22f4b4
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13876
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Michal Berger <michal.berger@intel.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-05 10:48:42 +00:00
vagrant
fa09c9ac9b lib/blob: Fix deleting a snapshot after decoupling it from its parent
When decoupling a snapshot from its parent, we need to clear its parent.
So we should remove the xattr BLOB_SNAPSHOT. Modifying the xattrs of a blob
only works if its metadata are not in read-only mode.
By default, a snapshot is in read-only mode so this operation fails. When we
later want to delete the snapshot, we will see that it has a parent, so we will
try to remove the snapshot from its parent's clones list. This will cause a
crash.
The fix is to remove the BLOB_SNAPSHOT xattr only after setting the snapshot's
metadata in rw mode.

Signed-off-by: Alex Michon <amichon@kalrayinc.com>
Change-Id: I80efa6dd3dcb38b4c738ce2e97aa2ffc281cefa5
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13723
Community-CI: Mellanox Build Bot
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
2022-08-05 08:30:30 +00:00
yidong0635
5de98ef86c reactor: Check error return for spdk_thread_lib_init_ext.
DPDK may use this NULL pointer to access its member,
And then got segmentation fault. But we only need it
exit or report normal error.

To minimize the impact, and to prevent these going on,
we add check the error return for creating NULL mempool
in spdk_thread_lib_init_ext in spdk_reactors_init.

when error returning from spdk_thread_lib_init_ext in spdk_reactors_init.
It contains thread_lib_init which reports error for failed mempool.

Thus, codes will return and will not cause segmentation fault.

Fixes issue #2620.

Signed-off-by: yidong0635 <dongx.yi@intel.com>
Change-Id: I63369fdaeb231196e8f8daa826eb5b057ed829b8
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13842
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Michal Berger <michal.berger@intel.com>
2022-08-05 08:29:53 +00:00
yidong0635
c9eb502a4a thread: Return -ENOMEM for no mempool.
Here should return -ENOMEM, and other places are
changed.

Signed-off-by: yidong0635 <dongx.yi@intel.com>
Change-Id: Id81cd7485733e66d996b1501061a45f774f2b51a
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13863
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Mellanox Build Bot
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Michal Berger <michal.berger@intel.com>
2022-08-05 08:29:53 +00:00
Michal Berger
261384fe46 pkgdep/git: Bump nvme-cli to v2.0 release
Older compilers (e.g. 7.5 on ubuntu1804) are having issues under
v1.16 due to:

plugins/intel/intel-nvme.c:666:47: error: initializer element is not constant
static const int LATENCY_STATS_V4_BASE_VAL = (
Makefile:108: recipe for target 'plugins/intel/intel-nvme.o' failed

This was fixed by the following commit which is present in the v2.0
release:

e7309044f3

Signed-off-by: Michal Berger <michal.berger@intel.com>
Change-Id: I7ebcf1b1fdb44500a21bcf3feceb07a722e8fc30
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13775
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-05 08:29:22 +00:00
Changpeng Liu
df38292ec3 test/nvmf/timeout.sh: use randread as the test case
The reconnect timeout test case expects a socket READ error
to trigger the reconnect poller in bdev_nvme module, but
we use the `verify` IO workload to send IO requests which
may cause the client doesn't receive any error, because
it will send WRITE commands first.

Fix issue #2595.

Change-Id: Ibc6b534d157552cdb2b55a03c869e254ec4c462e
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13840
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Michal Berger <michal.berger@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-05 08:29:11 +00:00
Karol Latecki
e8580900a2 doc: add Vhost 22.05 performance report link
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Change-Id: I45ec7edce2f20fdf081be84803573db63e257b74
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13866
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-05 08:28:54 +00:00
Karol Latecki
0c6300a356 doc: add NVMe-oF TCP 22.05 performance report link
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Change-Id: Ida3dae5c5c1a0b57a0bab04c47e97c3ac3072c29
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13865
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
2022-08-05 08:28:54 +00:00
tongkunkun
c8583472bd json: fix wrong param in json_parse_ut.c calling function 'spdk_json_parse'
the sizeof(g_vals) should be the num of array, not the num of bytes. see follow:

CU_ASSERT(spdk_json_parse(g_buf, sizeof(in) - 1, g_vals, sizeof(g_vals), &g_end, flags | SPDK_JSON_PARSE_FLAG_DECODE_IN_PLACE) == num_vals);

Fixes #2623

Signed-off-by: tongkunkun <tongkunkun_yewu@cmss.chinamobile.com>
Change-Id: I3b7994606284fe3464650337ecb0f723a627f7aa
Reported-by: Jim Harris <james.r.harris@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13841
Reviewed-by: GangCao <gang.cao@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-05 08:28:44 +00:00
Changpeng Liu
a02483e67c module/bdev_virtio_scsi: use the correct num_queues value
Parameter `num_queues` for virtio_scsi PCI device means
maximum number of queues, it SHOULD include the `eventq`
and `controlq`, while for `vhost_user` RPC call, it means
the number of IO queues, so here we use it as `max_queues`
in lib/virtio and add the fixed number queues for `vhost_user`
SCSI device.

Also fix `vhost_fuzz` to get `num_queues` earlier than
negotiate the feature bits.

Change-Id: I41b3da5e4b4dc37127befd414226ea6eafcd9ad0
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13791
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-04 11:24:40 +00:00
Changpeng Liu
515d028ec4 bdev/virtio_blk|scsi: don't negotiate VHOST_USER_F_BITS for PCI devices
VHOST_USER_F_PROTOCOL_FEATURES is used for `vhost_user` transport,
so unmask it for PCI devices.

Change-Id: If84d6c0ee7558886f14647dad07e41530e306206
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13790
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-04 11:24:40 +00:00
Changpeng Liu
84ac072e2c lib/virtio: eliminate virtio_user_backend_ops
The `vhost_user` socket transport APIs are already in the
same source file, so just call the function directly.

No code logic changes in this commit.

Change-Id: If471b9b0166d43591fb8614e95a17473c964e87c
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13789
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2022-08-04 11:24:40 +00:00
Changpeng Liu
4e6e7eafef lib/virtio: merge vhost_user.c and virtio_user.c into one source file
Similar with NVMe device driver, here `virtio` is a specification
abstraction library, `pci` and `vhost_user` are transports layer,
here we merge vhost_user.c and virtio_user.c into one new source
file `virtio_vhost_user.c` so that to make code more clear.

No logic change, just code movement in this commit.

Change-Id: I8e3e5c477e7c45e6eeebad240b8cc3c9476b86d1
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13788
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-04 11:24:40 +00:00
Michal Berger
be1883d978 lib/ftl: Fix -Wunused-function under clang
Builds under clang fail with the following:

  utils/ftl_mempool.c:45:1: error: unused function 'is_element_valid'
    [-Werror,-Wunused-function]
  is_element_valid(struct ftl_mempool *mpool, void *element)
  ^
  1 error generated.

Signed-off-by: Michal Berger <michal.berger@intel.com>
Change-Id: Ic776f3f226e9ea6ed9d0bbd0a3d8e2a0661e0d11
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13844
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Kamil Godzwon <kamilx.godzwon@intel.com>
Community-CI: Mellanox Build Bot
2022-08-04 07:30:59 +00:00
Changpeng Liu
c60cb1a8be lib/nvmf: don't raise assertion in nvmf_tgt_destroy_cb
While running into this function, even the subsystem can't be
destroyed due to error subsystem state, it's better to continue
the execution.

Continue to fix #2590, QEMU is stuck for the failure case, and
nvmf target should process such error because it may support other
normal subsystems at the same time.

Change-Id: Ib05e24996378b52070d2b760519f476f9b2d7e76
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13839
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2022-08-04 07:29:27 +00:00
Evgeniy Kochetov
3dd0bc9e09 nvme: Add transport controller ready step
This step allows custom transports to perform extra actions or checks
at controller initialization and fail initialization if required.

Signed-off-by: Evgeniy Kochetov <evgeniik@nvidia.com>
Change-Id: Ic7cadae5398a35903917ceace3828f4371be63a3
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12631
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <smatsumoto@nvidia.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2022-08-04 07:29:03 +00:00
paul luse
44cbea402e lib/accel: Add new RPC to get valid engine info.
The RPC provides a list of initialized engine names along with
that engine's supported operations.

Signed-off-by: paul luse <paul.e.luse@intel.com>
Change-Id: I59f9e5cb7aa51a6193f0bd2ec31e543a56c12f17
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13745
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
2022-08-03 07:53:21 +00:00
paul luse
c6ecddcc1c lib/accel: add RPC to get list of OP codes per module
In prep for upcoming patch that will provide an RPC to override
and automatic assignment of an op code to an engine.

Signed-off-by: paul luse <paul.e.luse@intel.com>
Change-Id: I17d4b962fb376a77f97ce051a513679d0fba698e
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12829
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2022-08-03 07:53:21 +00:00
Ben Walker
72285fa540 test/adq: Remove interrupt checks
SPDK has no control over how the interrupts work in the network stack.
SPDK can only group connections together based on their NAPI ID. So
remove this check from our tests. It's only going to result in
intermittent CI failures.

Change-Id: If8e6214b7d6c5aa4df99101612b98aa43d45b459
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13832
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2022-08-03 07:52:45 +00:00
Ben Walker
33f0321083 test/adq: Combine adq_configure_driver and adq_configure_traffic_classes
These are only called back-to-back and they're both configuring the
driver.

Change-Id: Icc07df1cf23d67954ac3621647b050d4c8c74e64
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13831
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
2022-08-03 07:52:45 +00:00
Ben Walker
5063e7f810 test/adq: Rename some functions to make it clear they're in the adq test
scope

Some of these names were hard to tell if they were common utilities or
ADQ test functions. Clarify the names.

Change-Id: If6998c3ea996ad6fef0a87a33c90d665c9accaa8
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13830
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
2022-08-03 07:52:45 +00:00
Bin Yang
1cddc829ff lib/scsi: use bkdr hash to avoid naa identifier collision
fix: If the first six characters of two scsi lun's name are the same,
such as aaaaaa0 and aaaaaa1, so do theirs naa identifier

Signed-off-by: Bin Yang <bin.yang@jaguarmicro.com>
Change-Id: I4e0541b372a0e20e95e0a24d62dd3d85b7abe230
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13824
Community-CI: Mellanox Build Bot
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-03 07:43:10 +00:00
Boris Glimcher
23f7470db8 doc: fix page formatting
Change-Id: I89386b21b2be4ddc08b226e9aa2e5a99cdbd5700
Signed-off-by: Boris Glimcher <Boris.Glimcher@emc.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13803
Reviewed-by: Shuhei Matsumoto <smatsumoto@nvidia.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-03 07:42:55 +00:00
yidong0635
5daedcc22e ftl: Fix compile warning.
Issue reports:

spdk/lib/ftl/ftl_io.c:121:9: warning: variable ‘result’
set but not used [-Wunused-but-set-variable]
  121 |  size_t result;
      |         ^~~~~~

Signed-off-by: yidong0635 <dongx.yi@intel.com>
Change-Id: I9ed7daea97f311ca33c4116299be32f275e33fbb
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13838
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: GangCao <gang.cao@intel.com>
Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
2022-08-03 07:42:38 +00:00
Changpeng Liu
3314f12bfd test/nvmf: use a more relax test condition
Also display the log when error happens.

Change-Id: I09040a2fee2379e7506701c7cb558f0d26a5de65
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13805
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Dong Yi <dongx.yi@intel.com>
Reviewed-by: Shuhei Matsumoto <smatsumoto@nvidia.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2022-08-03 01:26:10 +00:00
Artur Paszkiewicz
c6880a3974 ftl: superblock
Signed-off-by: Artur Paszkiewicz <artur.paszkiewicz@intel.com>
Signed-off-by: Kozlowski Mateusz <mateusz.kozlowski@intel.com>
Change-Id: Ic8ca0cd3bf3621ad5604e83ed24c0fa59a83f124
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13313
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>
2022-08-02 19:00:42 +00:00
Artur Paszkiewicz
f725ca81cf ftl: vss emulation
Signed-off-by: Artur Paszkiewicz <artur.paszkiewicz@intel.com>
Signed-off-by: Kozlowski Mateusz <mateusz.kozlowski@intel.com>
Change-Id: If22933834d640606526dec9185e849df367ac789
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13311
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>
2022-08-02 19:00:42 +00:00
Artur Paszkiewicz
884980d0aa ftl: vss null buffer workaround
Signed-off-by: Artur Paszkiewicz <artur.paszkiewicz@intel.com>
Signed-off-by: Kozlowski Mateusz <mateusz.kozlowski@intel.com>
Change-Id: I94ea399ed30fae29f92b4216eaa9209c02b3478b
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13310
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>
2022-08-02 19:00:42 +00:00
Artur Paszkiewicz
d67952540f ftl: wrappers for nv cache bdev io
Signed-off-by: Artur Paszkiewicz <artur.paszkiewicz@intel.com>
Signed-off-by: Kozlowski Mateusz <mateusz.kozlowski@intel.com>
Change-Id: I33d99ae35e2bd853a16a6d20336632a955679197
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13309
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>
2022-08-02 19:00:42 +00:00
Kozlowski Mateusz
950cce2c9e FTL: Add ftl_io unit tests
Signed-off-by: Kozlowski Mateusz <mateusz.kozlowski@intel.com>
Signed-off-by: Artur Paszkiewicz <artur.paszkiewicz@intel.com>
Change-Id: I1052fbfe7516b12e50e4bc4b3b7a4f452f56349f
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13308
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>
2022-08-02 19:00:42 +00:00
Artur Paszkiewicz
d9a631ad4c FTL: Add io channel logic
Signed-off-by: Kozlowski Mateusz <mateusz.kozlowski@intel.com>
Signed-off-by: Artur Paszkiewicz <artur.paszkiewicz@intel.com>
Change-Id: Ibf6bfbabc03c43e7938531c4fe08fde01ce02a3f
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13307
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>
2022-08-02 19:00:42 +00:00
Kozlowski Mateusz
e7a03e68e1 FTL: Add ftl_rq
Used for internal metadata update requests

Signed-off-by: Kozlowski Mateusz <mateusz.kozlowski@intel.com>
Signed-off-by: Artur Paszkiewicz <artur.paszkiewicz@intel.com>
Change-Id: I742ef2030070e7e159d4354159fb596b98742631
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13306
Community-CI: Mellanox Build Bot
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>
2022-08-02 19:00:42 +00:00
Artur Paszkiewicz
06790f25f1 FTL: Add ftl_io helper structure
Signed-off-by: Kozlowski Mateusz <mateusz.kozlowski@intel.com>
Signed-off-by: Artur Paszkiewicz <artur.paszkiewicz@intel.com>
Change-Id: I608b500c6fb14efe289932955f508484f2ecf1b6
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13305
Community-CI: Mellanox Build Bot
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>
2022-08-02 19:00:42 +00:00