Spdk/test/unit/lib/nvme
Shuhei Matsumoto 194047249b nvme_rdma: Get qpair from poll group using WC
NVMe-RDMA target has a helper function get_rdma_qpair_from_wc() and
uses it to identify a qpair from a WC.

NVMe-RDMA initiator has a similar function
nvme_rdma_poll_group_get_qpair_by_id().

NVMe-RDMA initiator will support SRQ in the following patches, and
it will want to identify a qpair from a WC.

get_rdma_qpair_from_wc() of NVMe-RDMA target uses wc->qp_num internally
anyway.

However, the upcoming custom transport for RDMA will have to use other
variables of WC.

Hence, it will be convenient to pass WC instead of qp_num if we consider
future enhancements.

Based on these thoughts, for NVMe-RDMA initiator rename
nvme_rdma_poll_group_get_qpair_by_id() by get_rdma_qpair_from_wc().
remove unnecessary declaration, and pass WC instead of qp_num.

Signed-off-by: Shuhei Matsumoto <smatsumoto@nvidia.com>
Signed-off-by: Denis Nagorny <denisn@nvidia.com>
Signed-off-by: Evgeniy Kochetov <evgeniik@nvidia.com>
Change-Id: I01ead4730207e2c6ac53b83f151bd5f977a11465
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/14279
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>
2022-10-28 06:27:19 +00:00
..
nvme_ctrlr_cmd.c lib/nvme: Do not submit queued aborts if adminq is in failed state. 2022-10-28 06:26:20 +00:00
nvme_ctrlr_ocssd_cmd.c check_format: For C files only, fix return type breaks 2022-06-27 09:33:48 +00:00
nvme_ctrlr.c nvme: Use spdk_nvme_ctrlr_is_fabrics() to update ioccsz 2022-08-12 08:59:52 +00:00
nvme_cuse.c UT/nvme_cuse: test for spdk_nvme_cuse_get_ctrlr_name 2022-10-26 07:28:37 +00:00
nvme_fabric.c nvme_fabrics: Lock mutext when prcessing set/get regs 2022-07-15 16:06:54 +00:00
nvme_io_msg.c check_format: For C files only, fix return type breaks 2022-06-27 09:33:48 +00:00
nvme_ns_cmd.c nvme: add support for verify command 2022-08-16 10:25:01 +00:00
nvme_ns_ocssd_cmd.c check_format: For C files only, fix return type breaks 2022-06-27 09:33:48 +00:00
nvme_ns.c check_format: For C files only, fix return type breaks 2022-06-27 09:33:48 +00:00
nvme_opal.c check_format: For C files only, fix return type breaks 2022-06-27 09:33:48 +00:00
nvme_pcie_common.c check_format: For C files only, fix return type breaks 2022-06-27 09:33:48 +00:00
nvme_pcie.c check_format: For C files only, fix return type breaks 2022-06-27 09:33:48 +00:00
nvme_poll_group.c Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
nvme_qpair.c nvme: Add ctrlr_abort_queued_aborts() into qpair_abort_all_queued_reqs() 2022-06-30 07:51:23 +00:00
nvme_quirks.c check_format: For C files only, fix return type breaks 2022-06-27 09:33:48 +00:00
nvme_rdma.c nvme_rdma: Get qpair from poll group using WC 2022-10-28 06:27:19 +00:00
nvme_tcp.c test/nvme_tcp: Correct the psh_len in nvme_tcp unittest 2022-09-20 20:29:40 +00:00
nvme_transport.c nvme: Polls only the qpair if ctrlr is not fabrics when connecting synchronously 2022-09-05 12:50:00 +00:00
nvme.c check_format: For C files only, fix return type breaks 2022-06-27 09:33:48 +00:00
Makefile Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00