From 6eb18e2f3d0bfb24847ef960c46c91401a9c95f0 Mon Sep 17 00:00:00 2001 From: Daniel Verkamp Date: Mon, 29 Feb 2016 10:11:35 -0700 Subject: [PATCH] nvme: rename nvme_qpair to spdk_nvme_qpair Prepare for qpair to be exposed as part of the public API. Change-Id: Ia63e863e95554adceeade20c829f12fe346375d5 Signed-off-by: Daniel Verkamp --- lib/nvme/nvme_ctrlr.c | 8 +-- lib/nvme/nvme_ctrlr_cmd.c | 4 +- lib/nvme/nvme_internal.h | 26 ++++----- lib/nvme/nvme_qpair.c | 58 +++++++++---------- .../nvme/unit/nvme_ctrlr_c/nvme_ctrlr_ut.c | 20 +++---- .../nvme/unit/nvme_qpair_c/nvme_qpair_ut.c | 28 ++++----- 6 files changed, 72 insertions(+), 72 deletions(-) diff --git a/lib/nvme/nvme_ctrlr.c b/lib/nvme/nvme_ctrlr.c index 570530c664..f99d12bd3e 100644 --- a/lib/nvme/nvme_ctrlr.c +++ b/lib/nvme/nvme_ctrlr.c @@ -179,7 +179,7 @@ nvme_ctrlr_construct_admin_qpair(struct spdk_nvme_ctrlr *ctrlr) static int nvme_ctrlr_construct_io_qpairs(struct spdk_nvme_ctrlr *ctrlr) { - struct nvme_qpair *qpair; + struct spdk_nvme_qpair *qpair; union spdk_nvme_cap_lo_register cap_lo; uint32_t i, num_entries, num_trackers; int rc; @@ -211,7 +211,7 @@ nvme_ctrlr_construct_io_qpairs(struct spdk_nvme_ctrlr *ctrlr) ctrlr->max_xfer_size = NVME_MAX_XFER_SIZE; - ctrlr->ioq = calloc(ctrlr->num_io_queues, sizeof(struct nvme_qpair)); + ctrlr->ioq = calloc(ctrlr->num_io_queues, sizeof(struct spdk_nvme_qpair)); if (ctrlr->ioq == NULL) return -1; @@ -491,7 +491,7 @@ static int nvme_ctrlr_create_qpairs(struct spdk_nvme_ctrlr *ctrlr) { struct nvme_completion_poll_status status; - struct nvme_qpair *qpair; + struct spdk_nvme_qpair *qpair; uint32_t i; if (nvme_ctrlr_construct_io_qpairs(ctrlr)) { @@ -924,7 +924,7 @@ void nvme_ctrlr_submit_io_request(struct spdk_nvme_ctrlr *ctrlr, struct nvme_request *req) { - struct nvme_qpair *qpair; + struct spdk_nvme_qpair *qpair; nvme_assert(nvme_thread_ioq_index >= 0, ("no ioq_index assigned for thread\n")); qpair = &ctrlr->ioq[nvme_thread_ioq_index]; diff --git a/lib/nvme/nvme_ctrlr_cmd.c b/lib/nvme/nvme_ctrlr_cmd.c index f349dddf18..174382f131 100644 --- a/lib/nvme/nvme_ctrlr_cmd.c +++ b/lib/nvme/nvme_ctrlr_cmd.c @@ -123,7 +123,7 @@ nvme_ctrlr_cmd_identify_namespace(struct spdk_nvme_ctrlr *ctrlr, uint16_t nsid, void nvme_ctrlr_cmd_create_io_cq(struct spdk_nvme_ctrlr *ctrlr, - struct nvme_qpair *io_que, spdk_nvme_cmd_cb cb_fn, + struct spdk_nvme_qpair *io_que, spdk_nvme_cmd_cb cb_fn, void *cb_arg) { struct nvme_request *req; @@ -151,7 +151,7 @@ nvme_ctrlr_cmd_create_io_cq(struct spdk_nvme_ctrlr *ctrlr, void nvme_ctrlr_cmd_create_io_sq(struct spdk_nvme_ctrlr *ctrlr, - struct nvme_qpair *io_que, spdk_nvme_cmd_cb cb_fn, void *cb_arg) + struct spdk_nvme_qpair *io_que, spdk_nvme_cmd_cb cb_fn, void *cb_arg) { struct nvme_request *req; struct spdk_nvme_cmd *cmd; diff --git a/lib/nvme/nvme_internal.h b/lib/nvme/nvme_internal.h index eeac6689c5..0791f602ff 100644 --- a/lib/nvme/nvme_internal.h +++ b/lib/nvme/nvme_internal.h @@ -237,7 +237,7 @@ struct nvme_tracker { uint64_t prp[NVME_MAX_PRP_LIST_ENTRIES]; }; -struct nvme_qpair { +struct spdk_nvme_qpair { volatile uint32_t *sq_tdbl; volatile uint32_t *cq_hdbl; @@ -329,7 +329,7 @@ struct spdk_nvme_ctrlr { volatile struct spdk_nvme_registers *regs; /** I/O queue pairs */ - struct nvme_qpair *ioq; + struct spdk_nvme_qpair *ioq; /** Array of namespaces indexed by nsid - 1 */ struct spdk_nvme_ns *ns; @@ -376,7 +376,7 @@ struct spdk_nvme_ctrlr { nvme_mutex_t ctrlr_lock; - struct nvme_qpair adminq; + struct spdk_nvme_qpair adminq; /** * Identify Controller data. @@ -450,10 +450,10 @@ void nvme_ctrlr_cmd_identify_namespace(struct spdk_nvme_ctrlr *ctrlr, uint16_t nsid, void *payload, spdk_nvme_cmd_cb cb_fn, void *cb_arg); void nvme_ctrlr_cmd_create_io_cq(struct spdk_nvme_ctrlr *ctrlr, - struct nvme_qpair *io_que, + struct spdk_nvme_qpair *io_que, spdk_nvme_cmd_cb cb_fn, void *cb_arg); void nvme_ctrlr_cmd_create_io_sq(struct spdk_nvme_ctrlr *ctrlr, - struct nvme_qpair *io_que, + struct spdk_nvme_qpair *io_que, spdk_nvme_cmd_cb cb_fn, void *cb_arg); void nvme_ctrlr_cmd_set_num_queues(struct spdk_nvme_ctrlr *ctrlr, uint32_t num_queues, spdk_nvme_cmd_cb cb_fn, @@ -478,18 +478,18 @@ void nvme_ctrlr_submit_io_request(struct spdk_nvme_ctrlr *ctrlr, void nvme_ctrlr_post_failed_request(struct spdk_nvme_ctrlr *ctrlr, struct nvme_request *req); -int nvme_qpair_construct(struct nvme_qpair *qpair, uint16_t id, +int nvme_qpair_construct(struct spdk_nvme_qpair *qpair, uint16_t id, uint16_t num_entries, uint16_t num_trackers, struct spdk_nvme_ctrlr *ctrlr); -void nvme_qpair_destroy(struct nvme_qpair *qpair); -void nvme_qpair_enable(struct nvme_qpair *qpair); -void nvme_qpair_disable(struct nvme_qpair *qpair); -int32_t nvme_qpair_process_completions(struct nvme_qpair *qpair, uint32_t max_completions); -void nvme_qpair_submit_request(struct nvme_qpair *qpair, +void nvme_qpair_destroy(struct spdk_nvme_qpair *qpair); +void nvme_qpair_enable(struct spdk_nvme_qpair *qpair); +void nvme_qpair_disable(struct spdk_nvme_qpair *qpair); +int32_t nvme_qpair_process_completions(struct spdk_nvme_qpair *qpair, uint32_t max_completions); +void nvme_qpair_submit_request(struct spdk_nvme_qpair *qpair, struct nvme_request *req); -void nvme_qpair_reset(struct nvme_qpair *qpair); -void nvme_qpair_fail(struct nvme_qpair *qpair); +void nvme_qpair_reset(struct spdk_nvme_qpair *qpair); +void nvme_qpair_fail(struct spdk_nvme_qpair *qpair); int nvme_ns_construct(struct spdk_nvme_ns *ns, uint16_t id, struct spdk_nvme_ctrlr *ctrlr); diff --git a/lib/nvme/nvme_qpair.c b/lib/nvme/nvme_qpair.c index ec80a4fffc..233a7675e9 100644 --- a/lib/nvme/nvme_qpair.c +++ b/lib/nvme/nvme_qpair.c @@ -38,12 +38,12 @@ * */ -static inline bool nvme_qpair_is_admin_queue(struct nvme_qpair *qpair) +static inline bool nvme_qpair_is_admin_queue(struct spdk_nvme_qpair *qpair) { return qpair->id == 0; } -static inline bool nvme_qpair_is_io_queue(struct nvme_qpair *qpair) +static inline bool nvme_qpair_is_io_queue(struct spdk_nvme_qpair *qpair) { return qpair->id != 0; } @@ -106,7 +106,7 @@ nvme_get_string(const struct nvme_string *strings, uint16_t value) } static void -nvme_admin_qpair_print_command(struct nvme_qpair *qpair, +nvme_admin_qpair_print_command(struct spdk_nvme_qpair *qpair, struct spdk_nvme_cmd *cmd) { @@ -117,7 +117,7 @@ nvme_admin_qpair_print_command(struct nvme_qpair *qpair, } static void -nvme_io_qpair_print_command(struct nvme_qpair *qpair, +nvme_io_qpair_print_command(struct spdk_nvme_qpair *qpair, struct spdk_nvme_cmd *cmd) { @@ -148,7 +148,7 @@ nvme_io_qpair_print_command(struct nvme_qpair *qpair, } static void -nvme_qpair_print_command(struct nvme_qpair *qpair, struct spdk_nvme_cmd *cmd) +nvme_qpair_print_command(struct spdk_nvme_qpair *qpair, struct spdk_nvme_cmd *cmd) { nvme_assert(qpair != NULL, ("qpair can not be NULL")); nvme_assert(cmd != NULL, ("cmd can not be NULL")); @@ -234,7 +234,7 @@ get_status_string(uint16_t sct, uint16_t sc) } static void -nvme_qpair_print_completion(struct nvme_qpair *qpair, +nvme_qpair_print_completion(struct spdk_nvme_qpair *qpair, struct spdk_nvme_cpl *cpl) { nvme_printf(qpair->ctrlr, "%s (%02x/%02x) sqid:%d cid:%d cdw0:%x sqhd:%04x p:%x m:%x dnr:%x\n", @@ -294,7 +294,7 @@ nvme_qpair_construct_tracker(struct nvme_tracker *tr, uint16_t cid, uint64_t phy } static void -nvme_qpair_submit_tracker(struct nvme_qpair *qpair, struct nvme_tracker *tr) +nvme_qpair_submit_tracker(struct spdk_nvme_qpair *qpair, struct nvme_tracker *tr) { struct nvme_request *req; @@ -313,7 +313,7 @@ nvme_qpair_submit_tracker(struct nvme_qpair *qpair, struct nvme_tracker *tr) } static void -nvme_qpair_complete_tracker(struct nvme_qpair *qpair, struct nvme_tracker *tr, +nvme_qpair_complete_tracker(struct spdk_nvme_qpair *qpair, struct nvme_tracker *tr, struct spdk_nvme_cpl *cpl, bool print_on_error) { struct nvme_request *req; @@ -365,7 +365,7 @@ nvme_qpair_complete_tracker(struct nvme_qpair *qpair, struct nvme_tracker *tr, } static void -nvme_qpair_manual_complete_tracker(struct nvme_qpair *qpair, +nvme_qpair_manual_complete_tracker(struct spdk_nvme_qpair *qpair, struct nvme_tracker *tr, uint32_t sct, uint32_t sc, uint32_t dnr, bool print_on_error) { @@ -381,7 +381,7 @@ nvme_qpair_manual_complete_tracker(struct nvme_qpair *qpair, } static void -nvme_qpair_manual_complete_request(struct nvme_qpair *qpair, +nvme_qpair_manual_complete_request(struct spdk_nvme_qpair *qpair, struct nvme_request *req, uint32_t sct, uint32_t sc, bool print_on_error) { @@ -408,7 +408,7 @@ nvme_qpair_manual_complete_request(struct nvme_qpair *qpair, } static inline bool -nvme_qpair_check_enabled(struct nvme_qpair *qpair) +nvme_qpair_check_enabled(struct spdk_nvme_qpair *qpair) { if (!qpair->is_enabled && !qpair->ctrlr->is_resetting) { @@ -462,7 +462,7 @@ nvme_qpair_check_enabled(struct nvme_qpair *qpair) * \sa nvme_cb_fn_t */ int32_t -nvme_qpair_process_completions(struct nvme_qpair *qpair, uint32_t max_completions) +nvme_qpair_process_completions(struct spdk_nvme_qpair *qpair, uint32_t max_completions) { struct nvme_tracker *tr; struct spdk_nvme_cpl *cpl; @@ -522,7 +522,7 @@ nvme_qpair_process_completions(struct nvme_qpair *qpair, uint32_t max_completion } int -nvme_qpair_construct(struct nvme_qpair *qpair, uint16_t id, +nvme_qpair_construct(struct spdk_nvme_qpair *qpair, uint16_t id, uint16_t num_entries, uint16_t num_trackers, struct spdk_nvme_ctrlr *ctrlr) { @@ -593,7 +593,7 @@ fail: } static void -nvme_admin_qpair_abort_aers(struct nvme_qpair *qpair) +nvme_admin_qpair_abort_aers(struct spdk_nvme_qpair *qpair) { struct nvme_tracker *tr; @@ -611,14 +611,14 @@ nvme_admin_qpair_abort_aers(struct nvme_qpair *qpair) } static void -_nvme_admin_qpair_destroy(struct nvme_qpair *qpair) +_nvme_admin_qpair_destroy(struct spdk_nvme_qpair *qpair) { nvme_admin_qpair_abort_aers(qpair); } void -nvme_qpair_destroy(struct nvme_qpair *qpair) +nvme_qpair_destroy(struct spdk_nvme_qpair *qpair) { struct nvme_tracker *tr; @@ -652,7 +652,7 @@ nvme_qpair_destroy(struct nvme_qpair *qpair) */ static void -_nvme_fail_request_bad_vtophys(struct nvme_qpair *qpair, struct nvme_tracker *tr) +_nvme_fail_request_bad_vtophys(struct spdk_nvme_qpair *qpair, struct nvme_tracker *tr) { /* * Bad vtophys translation, so abort this request and return @@ -664,7 +664,7 @@ _nvme_fail_request_bad_vtophys(struct nvme_qpair *qpair, struct nvme_tracker *tr } static void -_nvme_fail_request_ctrlr_failed(struct nvme_qpair *qpair, struct nvme_request *req) +_nvme_fail_request_ctrlr_failed(struct spdk_nvme_qpair *qpair, struct nvme_request *req) { nvme_qpair_manual_complete_request(qpair, req, SPDK_NVME_SCT_GENERIC, SPDK_NVME_SC_ABORTED_BY_REQUEST, true); @@ -674,7 +674,7 @@ _nvme_fail_request_ctrlr_failed(struct nvme_qpair *qpair, struct nvme_request *r * Build PRP list describing physically contiguous payload buffer. */ static int -_nvme_qpair_build_contig_request(struct nvme_qpair *qpair, struct nvme_request *req, +_nvme_qpair_build_contig_request(struct spdk_nvme_qpair *qpair, struct nvme_request *req, struct nvme_tracker *tr) { uint64_t phys_addr; @@ -718,7 +718,7 @@ _nvme_qpair_build_contig_request(struct nvme_qpair *qpair, struct nvme_request * } static int -_nvme_qpair_build_sgl_request(struct nvme_qpair *qpair, struct nvme_request *req, +_nvme_qpair_build_sgl_request(struct spdk_nvme_qpair *qpair, struct nvme_request *req, struct nvme_tracker *tr) { int rc; @@ -804,7 +804,7 @@ _nvme_qpair_build_sgl_request(struct nvme_qpair *qpair, struct nvme_request *req } void -nvme_qpair_submit_request(struct nvme_qpair *qpair, struct nvme_request *req) +nvme_qpair_submit_request(struct spdk_nvme_qpair *qpair, struct nvme_request *req) { int rc; struct nvme_tracker *tr; @@ -873,7 +873,7 @@ nvme_qpair_submit_request(struct nvme_qpair *qpair, struct nvme_request *req) } void -nvme_qpair_reset(struct nvme_qpair *qpair) +nvme_qpair_reset(struct spdk_nvme_qpair *qpair) { qpair->sq_tail = qpair->cq_head = 0; @@ -893,7 +893,7 @@ nvme_qpair_reset(struct nvme_qpair *qpair) } static void -_nvme_admin_qpair_enable(struct nvme_qpair *qpair) +_nvme_admin_qpair_enable(struct spdk_nvme_qpair *qpair) { struct nvme_tracker *tr; struct nvme_tracker *tr_temp; @@ -915,7 +915,7 @@ _nvme_admin_qpair_enable(struct nvme_qpair *qpair) } static void -_nvme_io_qpair_enable(struct nvme_qpair *qpair) +_nvme_io_qpair_enable(struct spdk_nvme_qpair *qpair) { STAILQ_HEAD(, nvme_request) temp; struct nvme_tracker *tr; @@ -949,7 +949,7 @@ _nvme_io_qpair_enable(struct nvme_qpair *qpair) } void -nvme_qpair_enable(struct nvme_qpair *qpair) +nvme_qpair_enable(struct spdk_nvme_qpair *qpair) { if (nvme_qpair_is_io_queue(qpair)) { _nvme_io_qpair_enable(qpair); @@ -959,20 +959,20 @@ nvme_qpair_enable(struct nvme_qpair *qpair) } static void -_nvme_admin_qpair_disable(struct nvme_qpair *qpair) +_nvme_admin_qpair_disable(struct spdk_nvme_qpair *qpair) { qpair->is_enabled = false; nvme_admin_qpair_abort_aers(qpair); } static void -_nvme_io_qpair_disable(struct nvme_qpair *qpair) +_nvme_io_qpair_disable(struct spdk_nvme_qpair *qpair) { qpair->is_enabled = false; } void -nvme_qpair_disable(struct nvme_qpair *qpair) +nvme_qpair_disable(struct spdk_nvme_qpair *qpair) { if (nvme_qpair_is_io_queue(qpair)) { _nvme_io_qpair_disable(qpair); @@ -982,7 +982,7 @@ nvme_qpair_disable(struct nvme_qpair *qpair) } void -nvme_qpair_fail(struct nvme_qpair *qpair) +nvme_qpair_fail(struct spdk_nvme_qpair *qpair) { struct nvme_tracker *tr; struct nvme_request *req; diff --git a/test/lib/nvme/unit/nvme_ctrlr_c/nvme_ctrlr_ut.c b/test/lib/nvme/unit/nvme_ctrlr_c/nvme_ctrlr_ut.c index 4f6d200a99..56c86e95ad 100644 --- a/test/lib/nvme/unit/nvme_ctrlr_c/nvme_ctrlr_ut.c +++ b/test/lib/nvme/unit/nvme_ctrlr_c/nvme_ctrlr_ut.c @@ -75,7 +75,7 @@ spdk_pci_device_get_subdevice_id(struct spdk_pci_device *dev) return g_pci_subdevice_id; } -int nvme_qpair_construct(struct nvme_qpair *qpair, uint16_t id, +int nvme_qpair_construct(struct spdk_nvme_qpair *qpair, uint16_t id, uint16_t num_entries, uint16_t num_trackers, struct spdk_nvme_ctrlr *ctrlr) { @@ -91,39 +91,39 @@ spdk_nvme_ctrlr_cmd_get_log_page(struct spdk_nvme_ctrlr *ctrlr, uint8_t log_page } void -nvme_qpair_fail(struct nvme_qpair *qpair) +nvme_qpair_fail(struct spdk_nvme_qpair *qpair) { } void -nvme_qpair_submit_request(struct nvme_qpair *qpair, struct nvme_request *req) +nvme_qpair_submit_request(struct spdk_nvme_qpair *qpair, struct nvme_request *req) { CU_ASSERT(req->cmd.opc == SPDK_NVME_OPC_ASYNC_EVENT_REQUEST); } int32_t -nvme_qpair_process_completions(struct nvme_qpair *qpair, uint32_t max_completions) +nvme_qpair_process_completions(struct spdk_nvme_qpair *qpair, uint32_t max_completions) { return 0; } void -nvme_qpair_disable(struct nvme_qpair *qpair) +nvme_qpair_disable(struct spdk_nvme_qpair *qpair) { } void -nvme_qpair_destroy(struct nvme_qpair *qpair) +nvme_qpair_destroy(struct spdk_nvme_qpair *qpair) { } void -nvme_qpair_enable(struct nvme_qpair *qpair) +nvme_qpair_enable(struct spdk_nvme_qpair *qpair) { } void -nvme_qpair_reset(struct nvme_qpair *qpair) +nvme_qpair_reset(struct spdk_nvme_qpair *qpair) { } @@ -153,14 +153,14 @@ nvme_ctrlr_cmd_set_num_queues(struct spdk_nvme_ctrlr *ctrlr, void nvme_ctrlr_cmd_create_io_cq(struct spdk_nvme_ctrlr *ctrlr, - struct nvme_qpair *io_que, spdk_nvme_cmd_cb cb_fn, + struct spdk_nvme_qpair *io_que, spdk_nvme_cmd_cb cb_fn, void *cb_arg) { } void nvme_ctrlr_cmd_create_io_sq(struct spdk_nvme_ctrlr *ctrlr, - struct nvme_qpair *io_que, spdk_nvme_cmd_cb cb_fn, + struct spdk_nvme_qpair *io_que, spdk_nvme_cmd_cb cb_fn, void *cb_arg) { } diff --git a/test/lib/nvme/unit/nvme_qpair_c/nvme_qpair_ut.c b/test/lib/nvme/unit/nvme_qpair_c/nvme_qpair_ut.c index 875e3ffff8..c32e72d898 100644 --- a/test/lib/nvme/unit/nvme_qpair_c/nvme_qpair_ut.c +++ b/test/lib/nvme/unit/nvme_qpair_c/nvme_qpair_ut.c @@ -157,7 +157,7 @@ nvme_free_request(struct nvme_request *req) static void test1(void) { - struct nvme_qpair qpair = {}; + struct spdk_nvme_qpair qpair = {}; struct spdk_nvme_cmd cmd = {}; outbuf[0] = '\0'; @@ -178,7 +178,7 @@ test1(void) static void test2(void) { - struct nvme_qpair qpair = {}; + struct spdk_nvme_qpair qpair = {}; struct spdk_nvme_cmd cmd = {}; outbuf[0] = '\0'; @@ -197,7 +197,7 @@ test2(void) } static void -prepare_submit_request_test(struct nvme_qpair *qpair, +prepare_submit_request_test(struct spdk_nvme_qpair *qpair, struct spdk_nvme_ctrlr *ctrlr, struct spdk_nvme_registers *regs) { @@ -212,13 +212,13 @@ prepare_submit_request_test(struct nvme_qpair *qpair, } static void -cleanup_submit_request_test(struct nvme_qpair *qpair) +cleanup_submit_request_test(struct spdk_nvme_qpair *qpair) { nvme_qpair_destroy(qpair); } static void -ut_insert_cq_entry(struct nvme_qpair *qpair, uint32_t slot) +ut_insert_cq_entry(struct spdk_nvme_qpair *qpair, uint32_t slot) { struct nvme_request *req; struct nvme_tracker *tr; @@ -256,7 +256,7 @@ expected_failure_callback(void *arg, const struct spdk_nvme_cpl *cpl) static void test3(void) { - struct nvme_qpair qpair = {}; + struct spdk_nvme_qpair qpair = {}; struct nvme_request *req; struct nvme_tracker *tr; struct spdk_nvme_ctrlr ctrlr = {}; @@ -295,7 +295,7 @@ test3(void) static void test4(void) { - struct nvme_qpair qpair = {}; + struct spdk_nvme_qpair qpair = {}; struct nvme_request *req; struct spdk_nvme_ctrlr ctrlr = {}; struct spdk_nvme_registers regs = {}; @@ -329,7 +329,7 @@ test4(void) static void test_sgl_req(void) { - struct nvme_qpair qpair = {}; + struct spdk_nvme_qpair qpair = {}; struct nvme_request *req; struct spdk_nvme_ctrlr ctrlr = {}; struct spdk_nvme_registers regs = {}; @@ -403,7 +403,7 @@ test_sgl_req(void) static void test_ctrlr_failed(void) { - struct nvme_qpair qpair = {}; + struct spdk_nvme_qpair qpair = {}; struct nvme_request *req; struct spdk_nvme_ctrlr ctrlr = {}; struct spdk_nvme_registers regs = {}; @@ -440,12 +440,12 @@ static void struct_packing(void) * that are used in the I/O path. Make sure the I/O path fields * all fit into two cache lines. */ - CU_ASSERT(offsetof(struct nvme_qpair, ctrlr) <= 128); + CU_ASSERT(offsetof(struct spdk_nvme_qpair, ctrlr) <= 128); } static void test_nvme_qpair_fail(void) { - struct nvme_qpair qpair = {}; + struct spdk_nvme_qpair qpair = {}; struct nvme_request *req = NULL; struct spdk_nvme_ctrlr ctrlr = {}; struct spdk_nvme_registers regs = {}; @@ -476,7 +476,7 @@ static void test_nvme_qpair_fail(void) static void test_nvme_qpair_process_completions(void) { - struct nvme_qpair qpair = {}; + struct spdk_nvme_qpair qpair = {}; struct spdk_nvme_ctrlr ctrlr = {}; struct spdk_nvme_registers regs = {}; @@ -491,7 +491,7 @@ static void test_nvme_qpair_process_completions(void) static void test_nvme_qpair_process_completions_limit(void) { - struct nvme_qpair qpair = {}; + struct spdk_nvme_qpair qpair = {}; struct spdk_nvme_ctrlr ctrlr = {}; struct spdk_nvme_registers regs = {}; @@ -522,7 +522,7 @@ test_nvme_qpair_process_completions_limit(void) static void test_nvme_qpair_destroy(void) { - struct nvme_qpair qpair = {}; + struct spdk_nvme_qpair qpair = {}; struct spdk_nvme_ctrlr ctrlr = {}; struct spdk_nvme_registers regs = {}; struct nvme_tracker *tr_temp;