Commit Graph

13337 Commits

Author SHA1 Message Date
Tomasz Zawadzki
35e54647fb intel-ipsec-mb: update submodule to v0.54
Updated required NASM version to 2.14,
since intel-ipsec-mb v0.54 now requires it.

Signed-off-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Change-Id: I10cee6aea941593b828a6a171297d7e997d0f30c
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/3868
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>
2020-09-22 11:40:50 +00:00
Darek Stojaczyk
30116833fa autobuild: add SPDK_TEST_NATIVE_DPDK to test again pristine DPDK master
This was previously done in a Jenkins script. Move it
to autobuild.sh inside the repo where we can all see it.
Use new meson/ninja build system while at it.

To test, use autorun.sh with the following cfg options:
SPDK_RUN_EXTERNAL_DPDK=/tmp/spdk/dpdk/build
SPDK_TEST_NATIVE_DPDK=1

SPDK_RUN_EXTERNAL_DPDK can point to a different path,
but needs to have correct access permissions for current
user,

I had to reorder some code in autobuild.sh. Since
SPDK_RUN_EXTERNAL_DPDK needs to specified the ./configure
script can't be run without existing dpdk directory,
so the dpdk build needs to happen before the initial
./configure as well as the ocf pre-build.

Change-Id: Ibc57094806b361dc3c6acf55942f04a938e5194f
Signed-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Signed-off-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/868
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2020-09-22 11:40:25 +00:00
Changpeng Liu
778e4c0020 nvmf: make nvmf_ctrlr_process_fabrics_cmd() as a static function
Unlike ADMIN and IO commands, the FABRIC command is only processed
in the ctrlr.c file.

Change-Id: Ic4e01c7f81c98631a2c7cb603343b301f8ba63e1
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4307
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2020-09-22 11:40:18 +00:00
Maciej Wawryk
fa5801703c test/vm_setup: Enable noninteractive packages install in debian like os
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: Idd43435d10ff54bb091a4a35cd0d803c7e62caf0
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4278
Reviewed-by: Michal Berger <michalx.berger@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2020-09-22 11:40:08 +00:00
Maciej Wawryk
1c62e9f828 scripts/vagrant: Remove unused openstack stuff
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: I92c1f303f805f536975652beddd41f0fad4012b5
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4154
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>
2020-09-22 11:40:01 +00:00
Niklas Cassel
069b536766 nvme_spec: add Zoned Namespace Command Set Specific identify data structures
Add the I/O Command Set Specific Identify Namespace Data Structure
and the I/O Command Set Specific Identify Controller Data Structure
for the Zoned Namespace Command Set.

These data structures are defined in the NVMe Zoned Namespace Command
Set Specification.

Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com>
Change-Id: I1434765ecbb22e1020c6b299cd05ba8a614b1cda
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4310
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Broadcom CI
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2020-09-22 11:39:53 +00:00
Niklas Cassel
d1db020954 nvme: add a csi parameter to nvme_ctrlr_cmd_identify()
With the introduction of namespace types, the identify command has
gained an additional parameter: Command Set Identifier (CSI).

This parameter is similar to the existing parameters NSID and CNTID,
and is not used by all CNS values.

Most notably, the CSI parameter is not used for the existing CNS
values 00h (ID NS) and 01h (ID CTRL).
There are new CNS values, e.g. 05h (ID IOCS specific NS), and
06h (ID IOCS specific CTRL), which do take the new CSI parameter.

The new CNS values instead return Command Set Specific data structures,
which is basically an additional data structure. Therefore, the CNS
values 00h and 01h are very much still in use.
(Even the NVM Command Set has a Command Set Specific data structure,
even though all fields in that data structure are currently reserved.)

Since the CSI parameter is unused by all the existing calls to
nvme_ctrlr_cmd_identify() (since none of the calls send in a CNS value
that uses CSI), simply send in 0 for all existing calls.
No functional change intended.

Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com>
Change-Id: Ia2b2324393a0707152b2f8511f0a22ad4a12bd46
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4309
Community-CI: Broadcom CI
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>
2020-09-22 11:39:53 +00:00
wanghailiangx
6ca498c197 script: fix a setup.sh error "No such file"
Error log as below:
06:27:53    # nvme_namespace_revert
06:27:53   # /home/storage/workspace/opal-end-to-end-reservation-autotest/spdk/scripts/setup.sh
/home/storage/workspace/opal-end-to-end-reservation-autotest/spdk/scripts/setup.sh: line 109: /sys/bus/pci/devices/0000:80:04.2/driver/remove_id: No such file or directory
home/storage/workspace/opal-end-to-end-reservation-autotest/spdk/scripts/setup.sh: line 110: /sys/bus/pci/devices/0000:80:04.2/driver/unbind: No such file or directory
 06:27:54 # trap - ERR

Change-Id: I302e58143f0e165b17a9b5edd14121e6282f55a7
Signed-off-by: wanghailiangx <hailiangx.e.wang@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4094
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Michal Berger <michalx.berger@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
2020-09-21 14:00:27 +00:00
Ben Walker
77ab6f2839 nvmf: Eliminate spdk_nvmf_tgt_accept()
The poller is now created internally to the library whenever a target
is constructed. Applications are not expected to poll for connections
any longer.

Change-Id: I523eb6adcc042c1ba2ed41b1cb41256b8bf63772
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/3583
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2020-09-21 07:55:54 +00:00
Michal Berger
4be6d32b97 pkgdep/git: Create etc directory in git's custom path
By default, git will use path relative to the prefix it was built
with to determine location of git{config,attributes} files. In
our case, that would be /usr/local/git/etc.

Lack of this directory may be problematic for vagrant's proxyconf
plugin. If it picks up git binary at our location, it will depend
on existance of the /usr/local/git/etc directory. In case it's
missing it simply fails as git won't create it on its own. To
avoid that, let's create it ourselves.

Change-Id: Ie1fadd36d5888866b20375a7184031c73058fe3d
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4292
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>
2020-09-18 07:36:52 +00:00
Michal Berger
3c98c8f764 scripts/vagrant: unset private_key_file when password auth is used
The main purpose of this is to force vagrant into using its own
ssh keys when password authentication is requested. Normally,
when ssh.password is defined, vagrant will attempt to inject its
own ssh key, by using provided password first, and re-use the key
for the new ssh session to provision the VM.

However, some vagrant boxes may come with their own embedded
Vagrantfiles which define custom ssh keys. If password auth is
requested for such boxes, vagrant will not use its own key, nor
the ones that may be defined by the vagrant box. Instead, it will
fallback to interactive, password authentication. From the CI pool
perspective this is not desirable.

On other note, this ties to the ongoing work of building indepdent
images for the CI where vagrant boxes will be deployed with a
custom ssh key alredy provided inside the box.

Related work:
trello.com/c/gAfo9mH1/208-vagrant-improvements-box-packaging
trello.com/c/9Dxp2Y9c/248-packaging-centos78-and-freebsd1112-with-packer

Change-Id: I49035b426519d9b24bcdab573d335ee622130560
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4283
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>
2020-09-18 07:36:52 +00:00
Michal Berger
d0ea1dfede scripta/vagrant: Fix unit typo in the help output
Change-Id: Idd707f20a0d8f6942606ec846ac27363000ddc80
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4282
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>
2020-09-18 07:36:52 +00:00
Michal Berger
47a87a0eb6 config/vm_setup: Don't fail on FreeBSD when os-release file is missing
Instead, define $ID, $VERSION_ID on our own based on FreeBSD's
version we are running on - 69d5d77bfb added etc_os-release package
as a pkg dependency so this change makes sure we have a chance to
actually install it.

Change-Id: I09b350ce3ae3f7c5d2f998f3d251f50e1277f846
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4261
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>
2020-09-18 07:36:52 +00:00
Michal Berger
aa46af008d scripts/vagrant: Don't expect an argument for -u option
This is a bool, hence it doesn't require any additional
arguments.

Change-Id: Ibc438f77c5c63ec5dc38007826268a494d8e661d
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4239
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>
2020-09-18 07:36:52 +00:00
Michal Berger
db31afaaef pkgdep/git: Rearrange order in which install_refspdk() is called
Since refspdk has its source built, we should give it a chance to
avoid any potential issues with missing dependencies. To do that,
let's run it at the very end after all other sources were already
put in place (this is mainly relevant to FreeBSD where cmdline
for ./configure is hardcoded).

Change-Id: Ic07129c7b879eff7fddd734c9c4a6787df3da7ec
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4190
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>
2020-09-18 07:36:52 +00:00
Michal Berger
b85b7e2b93 pkgdep/git: Don't indicate error if vagrant installation is not supported
This would unecessarily print out usage() and call exit which wouldn't
be respected since all sources (except {,ref}spdk) are installed in the
background anyway.

Also, since std{out,err} may be bloated with bunch of messages comming
from different sources, explicitly mention Vagrant name in the echo.

Change-Id: I737f5cf08d6ae3d2d494add143d1dfaf89beeead
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4189
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>
2020-09-18 07:36:52 +00:00
Michal Berger
4ea04101e0 pkgdep/git: Use -R instead of -r on freebsd for cp
On Linux, these two options have the same meaning, however, on FreeBSD
systems -r is treated as -RL. This dereferences all the symlinks copying
directly files they point at. This doesn't work very well with git since
it will detect that as a type change, aborting following checkout.

Use -R to make sure all special files are properly copied as well.

Change-Id: Ib066896cf730b0906bcd30449f1e98a31d70ff31
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4185
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>
2020-09-18 07:36:52 +00:00
Michal Berger
4a50398caf pkgdep/git: Call install_extra_pkgs() only on Linux distros
Change-Id: Ic93b83dab25957bd3d99527fccb9374f4f23d110
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4184
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>
Reviewed-by: John Kariuki <John.K.Kariuki@intel.com>
2020-09-18 07:36:52 +00:00
Michal Berger
d8956215ed pkgdep/git: Fix distro ID lookup for FreeBSD
Change-Id: I8fedd12c29479ef8b12d0604442f5bf1c29e7d86
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4183
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>
2020-09-18 07:36:52 +00:00
Michal Berger
c631e747af config/vm_setup: Add function placeholders
Change-Id: I4479afa3554065ab3f4826393732f6f45cedcf82
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4182
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>
2020-09-18 07:36:52 +00:00
Michal Berger
684b104389 scripts/pkgdep: Disable liburing installation on FreeBSD
Change-Id: Ifc5e28feacc27f1607a2aa19f3147c6cc9cad106
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4161
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>
Reviewed-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-by: John Kariuki <John.K.Kariuki@intel.com>
2020-09-18 07:36:52 +00:00
Michal Berger
3b102b4f57 scripts/pkgdep: Remove call to install_sfhmt from freebsd.sh
This function is now being called from common.sh instead.

Change-Id: I90df5e3ea543a96fcede33b90369371191dffd07
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4160
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>
2020-09-18 07:36:52 +00:00
Ben Walker
597ab5915a doc: Document log_get_flags
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Change-Id: I68fbc371ab360ecc1009d559542ca29671c16c92
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4256
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>
2020-09-18 07:25:15 +00:00
Ben Walker
92d6cc60bd doc: Document log_clear_flag RPC
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Change-Id: I70c2754a39a5f6a9cd4c6b78e818e7c9c46dcd8c
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4255
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2020-09-18 07:25:15 +00:00
Ben Walker
80d7b670b4 doc: Document log_set_flag RPC
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Change-Id: I9ab1b6b2b1c3d12ce3ed04172c8e165d989460ef
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4254
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2020-09-18 07:25:15 +00:00
Ben Walker
cacc10761f doc: Document log_get_level RPC
Change-Id: I68a0036a204af22266a7c4313ebc85af64e2526f
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4253
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>
2020-09-18 07:25:15 +00:00
Ben Walker
4fa81e020f doc: Document log_set_level RPC
Change-Id: If3b4d81501513e4b368e67dd9c9476fb1cf2dda3
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4252
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>
2020-09-18 07:25:15 +00:00
Ben Walker
5afe86cfa4 doc: Document log_get_print_level RPC
Change-Id: Ieb693fc9d977c57238e3b9dd1c86727a7bcdd7ec
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4251
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>
2020-09-18 07:25:15 +00:00
Ben Walker
34eb121016 doc: Document log_set_print_level RPC
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Change-Id: Ic9cd5f19b4e487569855a61575ca0cf83b971866
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4250
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>
2020-09-18 07:25:15 +00:00
Ben Walker
888c47d179 rpc: Fix header level of iscsi_portal_group_set_auth
It should be a level 2 heading

Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Change-Id: I6c23b6ac53c1a3c3ce53fde67ae3f4f40a2d43f1
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4109
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: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2020-09-18 07:25:15 +00:00
Ben Walker
1da395bc10 rpc: Document iscsi_initiator_group_remove_initiators
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Change-Id: I5c8adc433640b0f44222db73421896dfc01bb298
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4108
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: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2020-09-18 07:25:15 +00:00
Ben Walker
c04abc6398 rpc: Document bdev_examine
Change-Id: I6ad591479453fd1df812d241b7884fee9f6c2fbb
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4107
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>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2020-09-18 07:25:15 +00:00
Ben Walker
d61da0ccda scripts: Break check_format up into functions
Change-Id: I3e3bd44826453e0ff5cc5b01769e81b5fdd660ff
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4073
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>
2020-09-18 07:25:15 +00:00
Ben Walker
9f6f02f22e scripts: Detect shellcheck errors by looking at the length of
shellcheck.log

shellcheck does not seem to reliably return error codes, at least
on the 0.7.0 version packaged on Fedora. Instead, look at
whether shellcheck.log contains any output.

Change-Id: Iec3c4f416844eed6a6c75b9204e24c2bc7243f7a
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4072
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Michal Berger <michalx.berger@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2020-09-18 07:25:15 +00:00
Ben Walker
0ee7697e4d scripts: Always use tty mode for shellcheck
Even on version 0.7.0, the diff mode throws up a bunch of errors
that don't appear in the tty mode. We'll have to deal with those
at a later date.

Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Change-Id: Ic7001b9cf793e696bbf4bab0b0630e8d705a6905
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4071
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: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2020-09-18 07:25:15 +00:00
Niklas Cassel
726ac67c55 nvme: use the most appropriate is_active() function
There are two different is_active() functions.
spdk_nvme_ctrlr_is_active_ns() which iterates through the active_ns_list,
and spdk_nvme_ns_is_active(), which simply checks the nsdata.
There is an event callback that refreshes active_ns_list when a relevant
events has occured.

In nvme_ns_construct(), nvme_ctrlr_identify_ns() has just been called,
so we know that nsdata is as fresh as possible.

Hence, there is no reason to iterate through a less fresh active_ns_list.
Since we know that the nvme_ctrlr_identify_ns() call was done through the
same controller, we also know that the active/inactive is from the
perspective of the correct controller, so that is not a reason to use the
less efficient is_active() function.

Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com>
Change-Id: I185f59b53e16e70163e33a3909f4b55ebf631cc4
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4293
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>
2020-09-18 07:25:06 +00:00
Niklas Cassel
743271d92d nvme: cache the command set identifier
Since the command set identifier might be accessed at several
different states in the nvme state machine, cache it so that
we don't need to loop through the ns id desc list every time.

This is similar to how other identify fields are cached using
nvme_ns_set_identify_data().

None of the identifiers in the desc list (including the new CSI)
can change over the life time of a namespace, so caching them
should be safe.

Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com>
Change-Id: Ie06180a4b3750dfa1a42f47afe0f7f9e3ec04ba9
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4266
Community-CI: Broadcom CI
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>
2020-09-18 07:25:06 +00:00
Niklas Cassel
a7de7dee23 nvme: remove superfluous else statement
If the nvme completion was an error, the function will return,
so there is no reason for an else statement.

In fact, the else statement in nvme_ctrlr_identify_ns_async_done()
differs from the coding style used in other nvme_ctrlr_identify_*
functions, and arguably makes the code harder to read.

Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com>
Change-Id: If76b823b7ca04ab98abb2912927c344ee9f12314
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4265
Community-CI: Broadcom CI
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>
2020-09-18 07:25:06 +00:00
Niklas Cassel
c31fc45324 ut/nvme: use nvme_ns_construct()/nvme_ns_destruct() in nvme_ns_ut.c
Use nvme_ns_construct()/nvme_ns_destruct() for each subtest.
This is what lib/nvme uses when creating/deleting namespaces,
so it makes sense to use the same functions in the unit test.

If we explicitly call memset(), we might hide real problems,
since e.g. nvme_ns_destruct() does not clear all struct members
in struct spdk_nvme_ns.

Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com>
Change-Id: Ia0ffce3d0a29088282e9fc8fc5413b98d1fe7c63
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4264
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>
2020-09-18 07:25:06 +00:00
Niklas Cassel
07525a91b5 nvme: clear the ns id desc list in nvme_ns_destruct()
Clear the ns id desc list in nvme_ns_destruct().

Without this, someone can get stale data by calling e.g.
spdk_nvme_ns_get_uuid() on a destructed namespace.

Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com>
Change-Id: I965dd4cd6101d3a77eddbd582b9618b3436d39c8
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4263
Community-CI: Broadcom CI
Reviewed-by: Jim Harris <james.r.harris@intel.com>
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>
2020-09-18 07:25:06 +00:00
Jim Harris
792807a444 nvme: fix infinite loop when aborting queued reqs
When we disconnect a qpair, part of the code path is
calling _nvme_qpair_abort_queued_reqs.  This takes
care of aborting any requests that were queued waiting
for slots to open on the submission queue.
It walks the STAILQ one by one and manually completes
them with ABORT status back to the caller.

But if the callback path submits another request, this
request may also get queued to the end of the queued_req
TAILQ.  This can result in an infinite loop.

The solution is to use an STAILQ_SWAP to a local, empty
STAILQ.  Then we ensure we only abort the requests that
were queued when _nvme_qpair_abort_queued_reqs() started
executing.

Fixes issue #1588.

I used the multipath.sh test to reproduce this on my local
system. If it ever dropped into the STAILQ loop in this
function, we would hit the infinite loop.  With this patch,
I confirmed locally that now we safely avoid the infinite
loop and the test passes.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I657db23efe5983bd8613c870ad62695a7fc7f689
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4284
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: Ziye Yang <ziye.yang@intel.com>
Reviewed-by: <dongx.yi@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2020-09-17 21:34:58 +00:00
Changpeng Liu
5198fbeda8 test/blobfs: add 1 second delay before checking the mount point
The thread loop function fuse_loop_new_thread() may not be executed
before checking the mount point.

For #1572 case, only one notice log as follow:
"Mounting filesystem on bdev BlobfsBdev to path /tmp/spdk_tmp_mount..."

For normal cases, there are two notice messages:
"Mounting filesystem on bdev BlobfsBdev to path /tmp/spdk_tmp_mount..."
"blobfs_fuse.c: 267:fuse_loop_new_thread: NOTICE: Start to loop blobfs..."

So add 1 second delay here.

Change-Id: I8f36fa538cb8864c94fe8110ced38703b7e2e413
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4260
Community-CI: Broadcom CI
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>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2020-09-17 15:25:16 +00:00
Jim Harris
7d5318cfb1 nvmf/fc: simplify nvmf_fc_master_enqueue_event
Remove some of the boilerplate code from each case and
replace with just an spdk_msg_fn assignment.

This also reduces the size of an upcoming change needed
in this function.

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

Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4257
Reviewed-by: Anil Veerabhadrappa <anil.veerabhadrappa@broadcom.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>
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2020-09-17 15:25:09 +00:00
Li Feng
ae8c48d4bb vhost-scsi: support live recovery
When the vhost-scsi target needs live recovery, check the inflight share memory,
and resubmit the inflight io.

Signed-off-by: Li Feng <fengli@smartx.com>
Change-Id: I785476c8835053a4e8d4f1d692437feaf3a9ace1
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4092
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2020-09-17 15:25:03 +00:00
Tomasz Zawadzki
9b294aeaa6 ut/blob: fix CU_VERSION check for clear linux
On clear linux the # was interpreted as bash comment.
The result was that no file was included and CU_VERSION
was undetected.

Removing the backslash before hash resolves it on clearlinux,
but breaks on fedora 31. Workaround in this patch portable
for both, as strange as it looks.

For future reference:
Fedora 32, Make 4.2.1, gcc 10.2.1, bash 5.0.17
Clearlinux, Make 4.3, gcc 10.1.1, bash 5.0.16

While here, added more specific string detection for
CU_VERSION. Before patch e7a86c42 only CUnit header was scanned,
now other output from CC is. This will prevent accidental
matches in the future.

Fixes #1562

Signed-off-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Change-Id: Ia4aa9fcbc3ad810755cfecd745c5c1ecd2a70717
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4240
Community-CI: Broadcom CI
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2020-09-17 15:24:50 +00:00
Tomasz Zawadzki
a06628195e blobfs/fuse: add 'event' as dependency for blobfs_bdev
This was missed in CI, due to disabled SPDK_TEST_BLOBFS
test flag in UT job that performs check_so_deps.sh.

Error seen when it is enabled:
there was a dependency mismatch in the library blobfs_bdev
The makefile lists: 'bdev blob_bdev blobfs json jsonrpc log rpc thread util'
readelf outputs   : 'bdev blob_bdev blobfs event json jsonrpc log rpc thread util'

Temporary workarounds have been added, ignoring blobfs_dev
in the abi check test. This will allow for better transition
on CI side. After this patch is merged, UT job flags on CI will be
updated to include SPDK_TEST_BLOBFS and abi reference repository
will be recompiled with this flag.

Next patch in series removes this workaround. It will be merged
after work on CI side is done.

Signed-off-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Change-Id: I4753a918d5760f154d4a59349747a0b1356e9c91
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/3961
Community-CI: Broadcom CI
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>
2020-09-16 07:59:08 +00:00
Alexey Marchuk
e7c92b2426 nvme/tcp: Rename r2t_recv, set this flag when send_ack is 0
Rename ordering bit r2t_recv to h2c_send_waiting_ack, that is more
descriptive name.

Change-Id: I6d6143ff4c1cccc74e11226b7974706808092f9a
Signed-off-by: Alexey Marchuk <alexeymar@mellanox.com>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4202
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>
2020-09-16 07:58:59 +00:00
Alexey Marchuk
dc88d13129 nvme/tcp: Move tcp_req ordering bits to union
This makes it easier to zerofy ordering bits.

Change-Id: If5696bfedfff1bf75e41c1449eac7fccb469e98b
Signed-off-by: Alexey Marchuk <alexeymar@mellanox.com>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4201
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: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2020-09-16 07:58:59 +00:00
Alexey Marchuk
8db652e17e mk: Build crypto/qat when --with-reduce is specified
DPDK compilation fails when we configure SPDK using --with-reduce:
../drivers/common/qat/qat_qp.c:18:10: fatal error: qat_sym.h: No such file or directory
 #include "qat_sym.h"
          ^~~~~~~~~~~
But when SPDK is also configured using --with-crypto, DPDK is built successfully
--with-crypto enables build of crypto/qat driver and meson config for
this driver adds dpdk/driver/crypto/qat directory to QAT includes. This
directory contains the missing qat_sym.h and qat_sym_pmd.h files.

Group common drivers required by crypto/reduce

Fixes issue #1529

Change-Id: I7a53411798091e9a3c16442f3951ff73138d7337
Signed-off-by: Alexey Marchuk <alexeymar@mellanox.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4179
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2020-09-16 07:58:32 +00:00
Maciej Wawryk
2e2a0b947d scripts/vagrant: Change host ip in local.conf
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: I68766e986268352159114dc2ddc9104a17a31718
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4137
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Maciej Szwed <maciej.szwed@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2020-09-16 07:58:21 +00:00