Separate reference count of nvme_bdev_ctrlr between nvme_bdev_ctrlr
and nvme_bdev_ns.
Set ctrlr->ref to 1 when creating ctrlr, increment ctrlr->ref when
populating ns, decrement ctrlr->ref when destructing ctrlr or
when ns->ref becomes 0, and destruct ctrlr actually when ctrlr->ref is 0.
Set ns->ref to 1 when populating ns, increment ns->ref when
adding bdev to ns, decrement ns->ref when depopulating ns or removing
bdev from ns, and decrement ns->ctrlr->ref when ns->ref becomes 0.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I7810384d97a174d8f55d316e5cdf2a9ef4a11432
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5608
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
For further simplification, merge decrementing reference count of
nvme_bdev_ctrlr into nvme_bdev_ctrlr_destruct().
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I604039c3f38a60b316ae465d4649e9eb11bfb6cc
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5573
Community-CI: Broadcom CI
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>
destruct_poller had been used to destruct ctrlr after completing reset, but
we can remove destruct_poller and change reset processing to destruct ctrlr
after its completion by itself.
spdk_io_device_unregister() may fail spdk_for_each_channel(). Hence call
nvme_bdev_ctrlr_do_destruct() as the completion function of spdk_for_each_channel().
The first idea was to always run destruct_poller at nvme_bdev_ctrlr_destruct(),
but this patch will be simpler and more intuitive.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I43a400bdb67ab015d707fb9679693bd3d5bfb070
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5607
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: <dongx.yi@intel.com>
According to iSCSI 7143 spec 11.15.1 (3720 spec 10.15.1),
Rsph->response should be 0 if connection or session closed successfully.
The current code mistakenly compared cid provided by initiator with
inner conn->id parameter, which does not follow the spec.
Change-Id: I12dbb3471be5d49380c6b65bcdb67c57df11665f
Signed-off-by: ShadowMov <jinnian.hjn@alibaba-inc.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5731
Reviewed-by: Ziye Yang <ziye.yang@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>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This is done in order to workaround currently existing issues with
building spdk_abi_lts on systems with newer versions of the compiler.
Change-Id: I514580308f2cfbbffa13a821dcf72fc9fb60cd73
Signed-off-by: Michal Berger <michalx.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5716
Reviewed-by: Karol Latecki <karol.latecki@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>
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: I1933b1c3026c86b55c3e2b712bff02fa8f711bc7
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5446
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: I8b7777a89491b45ba785629679a34e0aa22f7e61
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5543
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: I5226c58f9993e0d1d8665ac75930ea952e474f05
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5542
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: I00998ce36b46902687065c5fa4684da9b7dd26d4
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5541
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: Karol Latecki <karol.latecki@intel.com>
1 For nbd_io in received list, we should not call nbd_put_io directly.
We should still let those I/O be executed by the lower bdev layer in SPDK.
2 For nbd io in executed_io_list, we should not directly put the nbd device.
The correct way is that we should write the io response to the kernel NBD
device. Then the nbd device will not hang.
Signed-off-by: Ziye Yang <ziye.yang@intel.com>
Change-Id: Ic031ca23241dd77ef47e6ac21f6c346e67f3ce28
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5720
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: <dongx.yi@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Current version provides unclear output
Change-Id: Ib044b00b5f91b1e363911f1b79c51c73c8a6920c
Signed-off-by: Alexey Marchuk <alexeymar@mellanox.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5743
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Transport specific request to abort is never null,
if we don't find a request by cid then we will abort the
last request.
Change-Id: Ie9eb55822b47381ae254e19266b9f3ffadbb67ea
Signed-off-by: Alexey Marchuk <alexeymar@mellanox.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5196
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
-A is equivalent to --pci-allowed, which recently
replaced -W/--pci-whitelist. But we missed adding
"A" to SPDK_APP_GETOPT_STRING, so -A was not actually
working.
Note that bdevperf was using -A to specify that timed
out I/O should be aborted. This patch changes it to
-X to avoid a conflict. It appears that something
broke with this option earlier this year though,
setting it has no actual effect. This should be
investigated separately from this patch.
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I2f1aaf0af4e82ba3d08e91e6f9046d485cf04549
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5645
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Originally introduced in:
"(8126509) rdma: replace improperly aligned buffers in requests."
This behaviour is for handling buffer split over two memory regions.
It is not unique to specific DPDK versions.
As such the comment and ERRLOG is not relevant here.
Signed-off-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Change-Id: I31bec435d92d8271d4a040855cfc4ff97f3d9d50
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5345
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
The purpose of this patch is to make spdk_bs_opts
for compatiblity issue.
Signed-off-by: Ziye Yang <ziye.yang@intel.com>
Change-Id: I26d2a6bc644feede64d48890c7903f224b1fc306
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5681
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
This function can be removed if we change the parameter type
in nvmf_tcp_request_free.
Change-Id: I4dbf0e7fa79c8c0115d7bcae99cb241aec367f1a
Signed-off-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5702
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
This patch includes the following work:
1 Add two fields in spdk_bdev_opts structure and make the
two fields configurable.
2 Update the unit test in bdev_ut.c
3 Revise the set_bdev_options rpc call and add the support
to use the two new fields.
Change-Id: Idd6073b3a3ffaba8161e3ffa9444a9e533e67f6d
Signed-off-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5664
Community-CI: Broadcom CI
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>
Purpose: In order to free all the allocated resources.
Our current code uses sync behaviour, and it will not wait for all
the resources are freed if there is active I/Os, and thus we will
not free some resources, e.g., some fds will not be closed.
Signed-off-by: Ziye Yang <ziye.yang@intel.com>
Change-Id: Iaf9a606da2049ffd0096860c46d89d094038a5ff
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5601
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Sun Zhenyuan <sunzhenyuan@baidu.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: <dongx.yi@intel.com>
The code changes, and this is not the second priority.
Signed-off-by: Ziye Yang <ziye.yang@intel.com>
Change-Id: I08fdac561f2d3f902763c39c37455727aa529b9f
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5663
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: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
There are transport types like vfio-user or fc for which this field is
optional so there is no need to explicitly specify it for the add
listener rpc. Still validation of this filed is preserved for rdma and
tcp transport.
Signed-off-by: Jacek Kalwas <jacek.kalwas@intel.com>
Change-Id: I6aef55bed45b3653472fd356e5a7cfead22c6f2b
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5605
Community-CI: Broadcom CI
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
First in a series of patches to change how batching is implemented.
Signed-off-by: paul luse <paul.e.luse@intel.com>
Change-Id: Iaee780cd948beee66a37528fdad6fc6841ea642b
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5486
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Mellanox Build Bot
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
It is optional to register i.e. most transports will not need to take
any action. It allows additional verification of ns/bdev capabilities
on transport layer before actual attachment to the subsystem.
Signed-off-by: Jacek Kalwas <jacek.kalwas@intel.com>
Change-Id: I07d96b1d33c2d5433b951cb418ae1a89bf9caea5
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5666
Community-CI: Broadcom CI
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: Aleksey Marchuk <alexeymar@mellanox.com>
It is not `only a notification` as by return value association can be
blocked.
Signed-off-by: Jacek Kalwas <jacek.kalwas@intel.com>
Change-Id: I19800bc8e278a335aaee972eecca7b3c7e3ac7e5
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5670
Community-CI: Broadcom CI
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
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>
blob_persist_clear_clusters() issues 'unmap' or 'write_zeroes'
IOs in one batch, this can consumes lots of 'bdev_io's.
we need to try best to merge the contiguous clusters
especially in the following case:
cluster 0: LBA 128 (count = 128)
cluster 1: LBA 0 (meaning thin provisioned, no cluster allocated)
cluster 2: LBA 256 (count = 128)
Besides, in the long run, we may need to do this batch by sequence.
Signed-off-by: Sochin Jiang <jiangxiaoqing.sochin@bytedance.com>
Change-Id: I436c8b46a1ee33ec127d0f43fd85b2c443689b59
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4082
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Mellanox Build Bot
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
This reverts commit 6d87bc7a8a.
There is an issue with the desing here i.e. lifetime of the subsystem
opts shall be associated with the subsystem but the transport specific
layer is not having any notification about that. As an alternative to
the transport specific subsystem opts listener interface was extended
in a previous commit.
Change-Id: I75c4e329e411a91694959db18ff1955774f0993e
Signed-off-by: Jacek Kalwas <jacek.kalwas@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5571
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Community-CI: Broadcom CI
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
With new spdk_nvmf_transport_listen function it should be possible to
add generic options without breaking API/ABI. For now it only delivers
json parameters which can be decoded on a transport specific layer.
This is similar to what was done for spdk_nvmf_transport_create and opts there.
Signed-off-by: Jacek Kalwas <jacek.kalwas@intel.com>
Change-Id: Iaf576248a0b10b408c4a3182785270be3e32ebe4
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5570
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Community-CI: Broadcom CI
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
We were using the stringified trtype which will always just print "CUSTOM" for pluggable transport
types. It is better to use the trstring since it will exactly print the transport name as requested.
Signed-off-by: Jacek Kalwas <jacek.kalwas@intel.com>
Change-Id: I5c184fe0ec209366339b658c647629d76bb8300b
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5643
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Community-CI: Broadcom CI
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
There are cases where spdk.common.mk can get included
more than once in a Makefile. So avoid duplication
in SYS_LIBS by initializing it before appending text
to it.
The duplication was harmless but a bit annoying.
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: Idf081f973e15a9ab6ec9211b9a3cbf02c736c7a0
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5676
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
-pthread is what SPDK in-tree Makefiles use, so use that
in the external_code Makefile too. -pthread can be
used both on the compilation and link stages.
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I8ef702b8fbde825a4191d961738ebc605b0aa4c5
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5675
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
The "external" module that we link against is essentially
a copy of the passthru bdev module in the modules/bdev
directory. But let's not use the same names for the
externally visible functions from this "external" module,
so that we don't get link errors if we happen to link
in both modules into one application.
This will help in a future patch where we use pkg-config
files to generate the list of the bdev modules.
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I835c7e7ee8902f6829657ec6a3cf40cd802a1357
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5674
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Our examples here show how to link in the DPDK environment
into an SPDK application. That includes both spdk_env_dpdk
library and the DPDK libraries. So put spdk_env_dpdk in
the DPDK_LIB variable in the Makefile.
This will also simplify a future patch where we will
use pkg-config in this Makefile instead.
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I2c389eaa9900dbe5f77ccee536bd4edc0a54cccc
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5673
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
test/external_make wants to always default to
the autotest_common.sh HUGEMEM default which is
8192MB on Linux. But it is useful to be able to
override this to run this test in VMs with less
memory.
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I23a40c6c14e35cffefbaf4fa993ebd28d1b0054c
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5672
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
This avoids duplicating it in several different
Makefiles.
Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I85f4886ec6744c23639d24867e2c68757dfeba32
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4484
Community-CI: Broadcom CI
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: Anil Veerabhadrappa <anil.veerabhadrappa@broadcom.com>
Reviewed-by: <dongx.yi@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Ziye Yang <ziye.yang@intel.com>
Here "return rc == -EINPROGRESS ? 0 : rc;"
They are the same meaning in these two functions.
Keep the comments here. This makes more clear to readers.
Signed-off-by: yidong0635 <dongx.yi@intel.com>
Change-Id: I8590de3f0fe27337163ee8b02ea63e166f1bbe7c
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5689
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
The following patches will need to update nvme_bdev_ns at
nvme_ctrlr_depopulate_namespace_done(). nvme_bdev_ctrlr can be
got from nvme_bdev_ns, and so this change will cause no issue.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I7cbfe0d936a3a757a8792fdf842e1228b2df05e6
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4531
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Move nvme_bdev_attach_bdev_to_ns() into nvme_bdev_create() and
change the return type of nvme_bdev_create() to int.
These refactorings are necessary to share a single nvme_bdev among
multiple nvme_bdev_ns.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I81c702bfec15f14c6b4a6588d1d3dfa28a9e3e6d
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5650
Community-CI: Broadcom CI
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
This will make us a little easier to understand nvme_bdev and clarify
the difference between nvme_bdev and ocssd_bdev.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: If6e93bcc315612ec88c452cf9ae87a3db8ec7855
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5649
Community-CI: Broadcom CI
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@mellanox.com>
This is a preparation for the next patch.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I20f7b03e15fe8cc74b22ff46040a4eba9cc63231
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5648
Community-CI: Broadcom CI
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@mellanox.com>