nvmf: remove zcopy check in spdk_nvmf_request_exec
It will make it possible to submit zero-copy requests through spdk_nvmf_request_exec(). Signed-off-by: Konrad Sztyber <konrad.sztyber@intel.com> Change-Id: Ibc14fe77cd477b11ed55d1350a7486caaad81add Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/10783 Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com> Community-CI: Mellanox Build Bot Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
7d23ac8657
commit
f65099d378
@ -4170,10 +4170,8 @@ spdk_nvmf_request_exec(struct spdk_nvmf_request *req)
|
||||
struct spdk_nvmf_transport *transport = qpair->transport;
|
||||
enum spdk_nvmf_request_exec_status status;
|
||||
|
||||
if (!spdk_nvmf_request_using_zcopy(req)) {
|
||||
if (!nvmf_check_subsystem_active(req)) {
|
||||
return;
|
||||
}
|
||||
if (!nvmf_check_subsystem_active(req)) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (SPDK_DEBUGLOG_FLAG_ENABLED("nvmf")) {
|
||||
|
@ -2579,13 +2579,7 @@ test_zcopy_read(void)
|
||||
CU_ASSERT(req.zcopy_bdev_io == zcopy_start_bdev_io_read);
|
||||
CU_ASSERT(qpair.outstanding.tqh_first == &req);
|
||||
CU_ASSERT(ns_info.io_outstanding == 1);
|
||||
|
||||
/* Execute the request */
|
||||
spdk_nvmf_request_exec(&req);
|
||||
CU_ASSERT(nvme_status_success(&rsp.nvme_cpl.status));
|
||||
CU_ASSERT(req.zcopy_bdev_io == zcopy_start_bdev_io_read);
|
||||
CU_ASSERT(qpair.outstanding.tqh_first == &req);
|
||||
CU_ASSERT(ns_info.io_outstanding == 1);
|
||||
|
||||
/* Perform the zcopy end */
|
||||
spdk_nvmf_request_zcopy_end(&req, false);
|
||||
@ -2593,6 +2587,7 @@ test_zcopy_read(void)
|
||||
CU_ASSERT(req.zcopy_phase == NVMF_ZCOPY_PHASE_COMPLETE);
|
||||
CU_ASSERT(qpair.outstanding.tqh_first == NULL);
|
||||
CU_ASSERT(ns_info.io_outstanding == 0);
|
||||
CU_ASSERT(nvme_status_success(&rsp.nvme_cpl.status));
|
||||
}
|
||||
|
||||
static void
|
||||
@ -2670,13 +2665,7 @@ test_zcopy_write(void)
|
||||
CU_ASSERT(req.zcopy_bdev_io == zcopy_start_bdev_io_write);
|
||||
CU_ASSERT(qpair.outstanding.tqh_first == &req);
|
||||
CU_ASSERT(ns_info.io_outstanding == 1);
|
||||
|
||||
/* Execute the request */
|
||||
spdk_nvmf_request_exec(&req);
|
||||
CU_ASSERT(nvme_status_success(&rsp.nvme_cpl.status));
|
||||
CU_ASSERT(req.zcopy_bdev_io == zcopy_start_bdev_io_write);
|
||||
CU_ASSERT(qpair.outstanding.tqh_first == &req);
|
||||
CU_ASSERT(ns_info.io_outstanding == 1);
|
||||
|
||||
/* Perform the zcopy end */
|
||||
spdk_nvmf_request_zcopy_end(&req, true);
|
||||
@ -2684,6 +2673,7 @@ test_zcopy_write(void)
|
||||
CU_ASSERT(req.zcopy_phase == NVMF_ZCOPY_PHASE_COMPLETE);
|
||||
CU_ASSERT(qpair.outstanding.tqh_first == NULL);
|
||||
CU_ASSERT(ns_info.io_outstanding == 0);
|
||||
CU_ASSERT(nvme_status_success(&rsp.nvme_cpl.status));
|
||||
}
|
||||
|
||||
static void
|
||||
|
Loading…
Reference in New Issue
Block a user