Commit Graph

6921 Commits

Author SHA1 Message Date
Ziye Yang
ef8e47571b net: make the net initialization in a correct way
Change-Id: If795ae841127a0742b366ac5df019e5a2d6e6b65
Signed-off-by: Ziye Yang <optimistyzy@gmail.com>
Reviewed-on: https://review.gerrithub.io/436901
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2018-12-20 01:37:50 +00:00
Seth Howell
672115fef4 nvme.c: break out parsing from trid parse
This code snippet will be generally useful for parsing information when
we add support for host address configuration.

Change-Id: Ic90f485de5a5db699901da029c9a29be4db477c7
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/437739
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-12-19 22:45:13 +00:00
Paul Luse
3d4c012a2e pkgdep: Handle SPDK CLI dep packages not available in old distros
At least one is not included in the 16.04 distro that we use
in the TP.

Change-Id: Ia441dbe1ddeb140313da5e61009ab84ea8e80ffd
Signed-off-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-on: https://review.gerrithub.io/436781
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>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-12-19 22:43:12 +00:00
Jim Harris
dbcbddbb22 test: mark iscsi_initiator.sh as executable
This fixes check_format.sh error.

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

Reviewed-on: https://review.gerrithub.io/437875
Reviewed-by: Seth Howell <seth.howell5141@gmail.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-12-19 19:16:08 +00:00
GangCao
70a3488657 bdev/qos: enable and disable when the QoS thread is not set
In the case the QoS thread has not properly initialized yet,
needs to go through the regular QoS enabling process to notify
all the channels and also disable the QoS properly. The channel
and poller related staff also needs to be handled together
with the thread.

Change-Id: Ifc2b2cdfb1181aa6418ad1d43ae5905c0c317549
Signed-off-by: GangCao <gang.cao@intel.com>
Reviewed-on: https://review.gerrithub.io/437519
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Xiaodong Liu <xiaodong.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-12-19 18:17:02 +00:00
Wojciech Malikowski
d1a6901c61 event: reactor loop delay configurable from cmdline
Change-Id: I38ab7b60d528fa9e0161ddba48c723601d8a6b78
Signed-off-by: Wojciech Malikowski <wojciech.malikowski@intel.com>
Reviewed-on: https://review.gerrithub.io/437142
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-12-19 17:22:33 +00:00
yidong0635
6907c36f2c test/common: add stop.sh in ceph setup testting
Add stop.sh before start.sh,to avoid reporting resource busy
it could lead to start failed.

Change-Id: I1756adaad31937a7a4b95fdc488f2334360d4ac2
Signed-off-by: yidong0635 <dongx.yi@intel.com>
Reviewed-on: https://review.gerrithub.io/437616
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-12-19 17:04:28 +00:00
Pawel Niedzwiecki
ebac2feba5 test/iscsi_tgt: Add iscsi performance test.
Change-Id: I6d236c91e9624f61b235c10f076ed43341a34d74
Signed-off-by: Pawel Niedzwiecki <pawelx.niedzwiecki@intel.com>
Reviewed-on: https://review.gerrithub.io/404757
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: John Kariuki <John.K.Kariuki@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-12-19 17:03:41 +00:00
yidong0635
23a95386c8 vagrant: add examples about installing virtualbox in README.md
Add examples for installing guide.
Before running a vagrant virtual machine or script, we need this.

Signed-off-by: yidong0635 <dongx.yi@intel.com>
Change-Id: I2f7ad8addf4300e75266d2b6fdf1b065eac0bb7c
Reviewed-on: https://review.gerrithub.io/436664
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Liang Yan <liang.z.yan@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2018-12-19 08:49:59 +00:00
Ben Walker
06a0d9ab33 test: Use ut_multithread framework in nvmf/ctrlr
Change-Id: I497abe0996287203f4b99850202a23f35d360f5e
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/422467
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2018-12-19 08:47:47 +00:00
yidong0635
c26bd15881 example/sock: avoid register poller multiple times
Timeout poller in hello_sock_quit which locates in hello_sock_accept_poll
can be registered multiple times, each poller allocates memory and
can't be freed.

fixed issue#521

Change-Id: I2730f0e53d99a525becca263c6731231adf5f64b
Signed-off-by: yidong0635 <dongx.yi@intel.com>
Reviewed-on: https://review.gerrithub.io/437226
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2018-12-19 01:45:04 +00:00
wuzhouhui
8db5ff2bdd reduce: _allocate_vol_requests: set pointer to NULL after freed
If _allocate_vol_requests() failed, the caller will call
_init_load_cleanup() to free memory that _allocate_vol_requests()
already freed, and cause segment fault. Setting pointer to NULL keeps
_init_load_cleanup() is safe to free it again.

Change-Id: I9ad09eabf6b65350f174bd5a4faf5ee643cbd23f
Signed-off-by: wuzhouhui <wuzhouhui@kingsoft.com>
Reviewed-on: https://review.gerrithub.io/437292
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-12-18 23:38:51 +00:00
wuzhouhui
3a4185be19 reduce: check strlen(SPDK_REDUCE_SIGNATURE) in buildtime
Change-Id: I4d12f2a693a4a34c840d972a4f60cbd0fc35011b
Signed-off-by: wuzhouhui <wuzhouhui@kingsoft.com>
Reviewed-on: https://review.gerrithub.io/437236
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-12-18 23:34:17 +00:00
wuzhouhui
7fbc5106e4 reduce: put pmem_unmap() in _init_load_cleanup()
In effect, this commit fixes error path of spdk_reduce_vol_init()
and spdk_reduce_vol_load(): forget to unmap pmem file after mapped.

Change-Id: I797f15e315fff3ff42c17509a73dc46e7f6bdb24
Signed-off-by: wuzhouhui <wuzhouhui@kingsoft.com>
Reviewed-on: https://review.gerrithub.io/437270
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-12-18 23:33:50 +00:00
Ben Walker
84b5a8c1d6 test: Use ut_multithread framework in nvmf subsystem unit test
Use the default thread implementation instead.

Change-Id: I844b02ba3c45d323e9f16b328a31b9d38dc8f754
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/422466
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-12-18 23:31:08 +00:00
Ben Walker
536beb1306 test: Use regular assert in allocate_threads
This allows us to call it during test set up instead of
only within a unit test.

Change-Id: I2daae8d630729b5e0712057766a3cba8812109e9
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/437479
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-12-18 23:31:08 +00:00
Ben Walker
7b94053827 thread: Rename spdk_thread_msg to spdk_msg_fn
This is the callback type used for message passing. The
old name is easy to confuse with the callback to pass
a message to a thread or the upcoming callback to
spawn a thread.

Change-Id: I5fd63b57c4be2a4262a197850e6de4901be03ee7
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/435941
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-12-18 23:31:08 +00:00
Ben Walker
978725c020 thread: Minimize scope of internal locking
Now that the thread is stored in a thread local
variable, the scope of the locking can be greatly
reduced.

Change-Id: Ic44934fff352be0fa5d54746226ef707aceae7b5
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/435940
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-12-18 23:31:08 +00:00
WangHaiLiang
93c7efbbe8 nvme/perf:Fix two small defects.
There are 2 #include "spdk/env.h" and an extra "]".

Change-Id: I7003333a164ef38ed166fbecf9e6b9f2df350ad9
Signed-off-by: WangHaiLiang <hailiangx.e.wang@intel.com>
Reviewed-on: https://review.gerrithub.io/416373
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-12-18 17:45:07 +00:00
Shuhei Matsumoto
e303567bc1 util/crc16: Add init_crc parameter as seed value to spdk_crc16_t10dif
Add init_crc parameter as seed value to spdk_crc16_t10dif API to generate
a CRC value spanning multiple separate buffers.

This will be necessary for upcoming DIF/DIX patches.

Having init_crc parameter is general, and so change the existing API
without adding seed version of the existing API.

Change-Id: I0ac7919b18013967e41829dcedd3e4e73204d5d6
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-on: https://review.gerrithub.io/437204
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-12-18 17:28:56 +00:00
WangHaiLiang
d49402fe5f doc: update a header file about bdev programming guide
The header file include/io_channel.h no longer exists.
Message passing infrastructure now is abstracted by thead.h.

Change-Id: I2fd6826d614ef5910787477eed75e81449625241
Signed-off-by: WangHaiLiang <hailiangx.e.wang@intel.com>
Reviewed-on: https://review.gerrithub.io/436118
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Liang Yan <liang.z.yan@intel.com>
2018-12-18 17:27:22 +00:00
Konrad Sztyber
62db4ac2cf util: added spdk_divide_round_up()
Replaced divide_round_up() from blobstore.c, lvol.c and reduce.c with
new spdk_divide_round_up() from util.h.

Change-Id: I013383ac286ca52b5c15c7fab4fb40ad97b92656
Signed-off-by: Konrad Sztyber <konrad.sztyber@intel.com>
Reviewed-on: https://review.gerrithub.io/437649
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-12-18 17:26:49 +00:00
WangHaiLiang
8114cd367a hotplug: annotated temporarily for no base_img
hotplug.sh skipped in NIGHTLY test for no VM image.
We disable the case temporarily before finding the
missing VM image.

Change-Id: I43afdaa647a85c8fc2c846f79b26885fd541b3f8
Signed-off-by: WangHaiLiang <hailiangx.e.wang@intel.com>
Reviewed-on: https://review.gerrithub.io/431097
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-12-18 17:25:46 +00:00
Ben Walker
8c89954d4b test: Sanitize log file
This patch removes the "sshpass -p intel" from the test logs. This
trips up security analysis tools which flag it (falsely) as a leaked
password.

Change-Id: Id8e470561429821e320cdf185c43204938110c75
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/436891
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-12-18 17:22:25 +00:00
Lance Hartmann
fe34909871 setup.sh: Fix cleanup in matching files
The original mechanism to identify files to cleanup
relied on glob matching from the output of 'echo'
piped to a grep.  This yields a case where some
objects can appear and picked up as matching because
other items on the same line matched the grep
string.   Changing this to use 'ls -1' which will
restrict the grep string matching to individual lines
thereby only picking up the entities the script
intended to do.

Change-Id: I020c80236fa68bcabeca0299fe7a27f3320de97b
Signed-off-by: Lance Hartmann <lance.hartmann@oracle.com>
Reviewed-on: https://review.gerrithub.io/437380
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
2018-12-18 08:40:14 +00:00
Ziye Yang
94cd652b18 nvmf/tcp: Add a poller to check the timeout of each qpair
This makes the timeout check for each qpair in the group
efficient. If there are many qpairs in the group, we
can scale.

Change-Id: I75c29a92107dc32377a2ef7edb5ac92868f1c5df
Signed-off-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-on: https://review.gerrithub.io/435277
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2018-12-18 08:34:30 +00:00
Ziye Yang
9d11abfd0e nvmf: Do not set the error state of the qpair
Reason: I checked the code in different transport,
the qpair is already freed, so we dot need to set
any state.

Change-Id: I3d78c259c3f79ea4426dc9408e5c3469bc171358
Signed-off-by: Ziye Yang <optimistyzy@gmail.com>
Reviewed-on: https://review.gerrithub.io/437493
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2018-12-18 04:00:59 +00:00
Tomasz Kulasek
c68c2d28c1 test/iscsi_tgt: fixup bytes to str for python 3.5
Change-Id: Ia73e950c746fb23f1188dc09a4a34c8ba5f97985
Signed-off-by: Tomasz Kulasek <tomaszx.kulasek@intel.com>
Reviewed-on: https://review.gerrithub.io/436680
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@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>
2018-12-17 19:41:15 +00:00
Ziye Yang
04d09f9207 nvmf/tcp: Use generic transport options structure
Remove the unnessary fields in spdk_nvmf_tcp_transport

Change-Id: I632608ba654b30f3511f5e1d925c6743c9100365
Signed-off-by: Ziye Yang <optimistyzy@gmail.com>
Reviewed-on: https://review.gerrithub.io/437271
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2018-12-17 04:25:25 +00:00
wuzhouhui
c14dd64467 include/reduce: remove declaration of non-existent function
Since commit 0b0af8f30b (reduce: calculate vol size from backing dev size)
removes definition of spdk_reduce_get_backing_device_size(), the declaration
of it should be removed as well.

Change-Id: Id5ce3776fa4e119ff771f6bee9c06e09bfc842ce
Signed-off-by: wuzhouhui <wuzhouhui@kingsoft.com>
Reviewed-on: https://review.gerrithub.io/437217
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@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>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-12-14 23:26:51 +00:00
Liu Xiaodong
ae0aae1532 lib/trace: add 3 RPC method for tpoint_group_mask
Now trace facility can be enabled/disabled at runtime,
besides app starting parameters

Change-Id: I086564665ba4375b946a5339d5921d6584e9bfda
Signed-off-by: Liu Xiaodong <xiaodong.liu@intel.com>
Reviewed-on: https://review.gerrithub.io/435470
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-12-14 21:29:12 +00:00
Ben Walker
605e530a4e thread: Use TLS to accelerate thread look up
Change-Id: I8136db265c9cb8d61de4845ce6eaff2351b5b597
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/435939
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-12-14 18:54:03 +00:00
Ben Walker
70642bcbe8 rocksdb: Use new threading API calls
Change-Id: I6ed98605512b675e1b6bde5b9644d6160802b893
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/436757
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-12-14 18:54:03 +00:00
Ben Walker
5d81ab16d4 fio: Open bdevs inside a thread message
This ensures that these operations occur on an SPDK thread

Change-Id: I265c814a289bdb8c95421c2675b35bf8c0074cc3
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/436554
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-12-14 18:54:03 +00:00
Ben Walker
443c6e401b fio: Close bdevs inside of a thread message
This ensures that it runs on an SPDK thread.

Change-Id: If57161ebafe97d592fe6ffec1a7aa135beebdc7a
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/436553
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2018-12-14 18:54:03 +00:00
Ben Walker
b9cdb813fe fio: Do bdev shutdown in a thread message
This ensures that it occurs on an SPDK thread

Change-Id: I62d15d6b0fd4fe56939c664e44eecd3199014292
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/436552
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-12-14 18:54:03 +00:00
Ben Walker
c4f0818bd3 fio: Perform bdev initialization inside a thread message
This ensures that these calls are executed on an SPDK thread.

Change-Id: I8cb4ee48c2f8bf4604e478e71e97bda856b6f0d0
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/436551
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-12-14 18:54:03 +00:00
Evgeniy Kochetov
d722a1742d nvmf: Improve error handling in spdk_nvmf_transport_poll_group_create
At least in case of RDMA transport, poll_group_create (spdk_nvmf_rdma_poll_group_create)
 can return error (NULL).

Change-Id: If1576b3515e7f9ede76af08bfa6b1c8399dcda09
Signed-off-by: Sasha Kotchubievsky <sashakot@mellanox.com>
Signed-off-by: Evgeniy Kochetov <evgeniik@mellanox.com>
Reviewed-on: https://review.gerrithub.io/436887
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-12-14 16:15:48 +00:00
Evgeniy Kochetov
7da9f8faba nvmf/rdma: Fix refcnt check on RDMA QP destroy
Check for QP reference counter in RDMA QP destroy function was wrong
and QP resources were never released.

Change-Id: I6ab0ce39452e8263f89589d138c90f749516ebb1
Signed-off-by: Evgeniy Kochetov <evgeniik@mellanox.com>
Signed-off-by: Sasha Kotchubievsky <sashakot@mellanox.com>
Reviewed-on: https://review.gerrithub.io/436974
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
2018-12-14 16:15:12 +00:00
Wojciech Malikowski
212eb89376 util: added bit array bitmask load, store and clear
Change-Id: I7cd47184d0dfb038297c0ac04d7dfb5d31f96b6b
Signed-off-by: Wojciech Malikowski <wojciech.malikowski@intel.com>
Reviewed-on: https://review.gerrithub.io/432537
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Pawel Wodkowski <pawelx.wodkowski@intel.com>
2018-12-14 15:34:53 +00:00
Seth Howell
7245134ab0 memory: return first translation from mem_map_translate
This should have always been the case with spdk_mem_map_translate. For
some memory maps (like RDMA) this doesn't matter, but for others like
our virtual to physical map, this is critical for retrieving valid
translations.

This behavior change will only affect maps that have a registered
contiguous memory callback.

Change-Id: I67517667f01d974702d7daa7c81238281aae0cf6
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/436562
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-12-13 22:27:21 +00:00
Maciej Szwed
54f6083a81 blob: Remove snpashot from the list only on blob deletion
When last clone of a snapshot is being deleted
we remove that snapshot from snapshots list.
We should not do that as it still works as a
snapshot and it is read-only, but it does not list
as a snpashot from get_bdevs. Instead remove snapshot
entry from the list when blob that represents that
snapshot is being removed.

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

Reviewed-on: https://review.gerrithub.io/436971
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-12-13 22:26:56 +00:00
Ziye Yang
ea8aa1bf0a nvmf: check the qpair->ctrlr
The ctrlr may be NULL, so we need to add a check here
to present segment fault.

Change-Id: I6c5361cc829af065082a95df0b8cc2f8d49a6002
Signed-off-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-on: https://review.gerrithub.io/436950
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Maciej Szwed <maciej.szwed@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-12-13 21:52:45 +00:00
Jim Harris
35f401adcf test/rocksdb: only use 2GB cache for per-patch testing
We can still use 4GB for nightly testing, but cutting
the cache size to 2GB reduces the setup time for each
of the 5 db_bench test runs.

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

Reviewed-on: https://review.gerrithub.io/436564
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2018-12-13 21:52:12 +00:00
Jim Harris
3d1c1f945c reduce: don't try to clear io units for empty chunk maps
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Reported-by: Shuhei Matsumoto
Change-Id: Idcf427e32962236acfeb7dab793e27c44cdc6151

Reviewed-on: https://review.gerrithub.io/436878
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2018-12-13 14:55:39 +00:00
Jim Harris
0b0af8f30b reduce: calculate vol size from backing dev size
This more closely matches the sequence of events
a user will take in creating a compressed volume.

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

Reviewed-on: https://review.gerrithub.io/436065
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-12-13 14:55:39 +00:00
Jim Harris
8c2cf577b3 reduce: remove extra size check
This was the result of a previous merge conflict.

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

Reviewed-on: https://review.gerrithub.io/436063
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-12-13 14:55:39 +00:00
Jim Harris
1c68d71107 reduce: change some member names to make them more descriptive
Based on feedback from Paul Luse in some earlier reviews.

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

Reviewed-on: https://review.gerrithub.io/435368
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-12-13 14:55:39 +00:00
Jim Harris
212770db66 test/reduce: test 512 byte backing blocklen
Parameterize the existing unit tests to maximize
code reuse.

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

Reviewed-on: https://review.gerrithub.io/434117
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2018-12-13 14:55:39 +00:00
Jim Harris
383b117309 reduce: implement read and write with data
For write operations, copy data to req->buf and write
to disk.

If chunk already specified in logical map, read the
chunk first into req->buf, and overwrite with data
specified by the write operation.

If chunk not specified in logical map, fill logical
blocks not specified by the write operation with
zeroes.

For read operations, read chunk into req->buf first,
then copy relevant data into the buffers specified
by the read operations.

These operations are all functional, but have room
for future improvement.  For example, this patch
will issue a separate backing read/write operations
for each backing block in the chunk - this could be
optimized to coalesce operations where the backing
blocks are contiguous.

While here, clean up freeing bufspace in one of
the error paths - this needs to be freed using
spdk_dma_free instead.

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

Reviewed-on: https://review.gerrithub.io/434116
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2018-12-13 14:55:39 +00:00