Lines Matching refs:queue

48 	struct nvmet_rdma_queue	*queue;  member
63 struct nvmet_rdma_queue *queue; member
170 static void nvmet_rdma_queue_disconnect(struct nvmet_rdma_queue *queue);
210 nvmet_rdma_get_rsp(struct nvmet_rdma_queue *queue) in nvmet_rdma_get_rsp() argument
215 spin_lock_irqsave(&queue->rsps_lock, flags); in nvmet_rdma_get_rsp()
216 rsp = list_first_entry_or_null(&queue->free_rsps, in nvmet_rdma_get_rsp()
220 spin_unlock_irqrestore(&queue->rsps_lock, flags); in nvmet_rdma_get_rsp()
228 ret = nvmet_rdma_alloc_rsp(queue->dev, rsp); in nvmet_rdma_get_rsp()
246 nvmet_rdma_free_rsp(rsp->queue->dev, rsp); in nvmet_rdma_put_rsp()
251 spin_lock_irqsave(&rsp->queue->rsps_lock, flags); in nvmet_rdma_put_rsp()
252 list_add_tail(&rsp->free_list, &rsp->queue->free_rsps); in nvmet_rdma_put_rsp()
253 spin_unlock_irqrestore(&rsp->queue->rsps_lock, flags); in nvmet_rdma_put_rsp()
452 nvmet_rdma_alloc_rsps(struct nvmet_rdma_queue *queue) in nvmet_rdma_alloc_rsps() argument
454 struct nvmet_rdma_device *ndev = queue->dev; in nvmet_rdma_alloc_rsps()
455 int nr_rsps = queue->recv_queue_size * 2; in nvmet_rdma_alloc_rsps()
458 queue->rsps = kcalloc(nr_rsps, sizeof(struct nvmet_rdma_rsp), in nvmet_rdma_alloc_rsps()
460 if (!queue->rsps) in nvmet_rdma_alloc_rsps()
464 struct nvmet_rdma_rsp *rsp = &queue->rsps[i]; in nvmet_rdma_alloc_rsps()
470 list_add_tail(&rsp->free_list, &queue->free_rsps); in nvmet_rdma_alloc_rsps()
477 struct nvmet_rdma_rsp *rsp = &queue->rsps[i]; in nvmet_rdma_alloc_rsps()
482 kfree(queue->rsps); in nvmet_rdma_alloc_rsps()
487 static void nvmet_rdma_free_rsps(struct nvmet_rdma_queue *queue) in nvmet_rdma_free_rsps() argument
489 struct nvmet_rdma_device *ndev = queue->dev; in nvmet_rdma_free_rsps()
490 int i, nr_rsps = queue->recv_queue_size * 2; in nvmet_rdma_free_rsps()
493 struct nvmet_rdma_rsp *rsp = &queue->rsps[i]; in nvmet_rdma_free_rsps()
498 kfree(queue->rsps); in nvmet_rdma_free_rsps()
513 ret = ib_post_recv(cmd->queue->qp, &cmd->wr, NULL); in nvmet_rdma_post_recv()
521 static void nvmet_rdma_process_wr_wait_list(struct nvmet_rdma_queue *queue) in nvmet_rdma_process_wr_wait_list() argument
523 spin_lock(&queue->rsp_wr_wait_lock); in nvmet_rdma_process_wr_wait_list()
524 while (!list_empty(&queue->rsp_wr_wait_list)) { in nvmet_rdma_process_wr_wait_list()
528 rsp = list_entry(queue->rsp_wr_wait_list.next, in nvmet_rdma_process_wr_wait_list()
532 spin_unlock(&queue->rsp_wr_wait_lock); in nvmet_rdma_process_wr_wait_list()
534 spin_lock(&queue->rsp_wr_wait_lock); in nvmet_rdma_process_wr_wait_list()
537 list_add(&rsp->wait_list, &queue->rsp_wr_wait_list); in nvmet_rdma_process_wr_wait_list()
541 spin_unlock(&queue->rsp_wr_wait_lock); in nvmet_rdma_process_wr_wait_list()
636 struct rdma_cm_id *cm_id = rsp->queue->cm_id; in nvmet_rdma_rw_ctx_init()
655 struct rdma_cm_id *cm_id = rsp->queue->cm_id; in nvmet_rdma_rw_ctx_destroy()
670 struct nvmet_rdma_queue *queue = rsp->queue; in nvmet_rdma_release_rsp() local
672 atomic_add(1 + rsp->n_rdma, &queue->sq_wr_avail); in nvmet_rdma_release_rsp()
680 if (unlikely(!list_empty_careful(&queue->rsp_wr_wait_list))) in nvmet_rdma_release_rsp()
681 nvmet_rdma_process_wr_wait_list(queue); in nvmet_rdma_release_rsp()
686 static void nvmet_rdma_error_comp(struct nvmet_rdma_queue *queue) in nvmet_rdma_error_comp() argument
688 if (queue->nvme_sq.ctrl) { in nvmet_rdma_error_comp()
689 nvmet_ctrl_fatal_error(queue->nvme_sq.ctrl); in nvmet_rdma_error_comp()
696 nvmet_rdma_queue_disconnect(queue); in nvmet_rdma_error_comp()
704 struct nvmet_rdma_queue *queue = wc->qp->qp_context; in nvmet_rdma_send_done() local
712 nvmet_rdma_error_comp(queue); in nvmet_rdma_send_done()
720 struct rdma_cm_id *cm_id = rsp->queue->cm_id; in nvmet_rdma_queue_response()
741 nvmet_rdma_post_recv(rsp->queue->dev, rsp->cmd); in nvmet_rdma_queue_response()
743 ib_dma_sync_single_for_device(rsp->queue->dev->device, in nvmet_rdma_queue_response()
757 struct nvmet_rdma_queue *queue = wc->qp->qp_context; in nvmet_rdma_read_data_done() local
761 atomic_add(rsp->n_rdma, &queue->sq_wr_avail); in nvmet_rdma_read_data_done()
771 nvmet_rdma_error_comp(queue); in nvmet_rdma_read_data_done()
790 struct nvmet_rdma_queue *queue = wc->qp->qp_context; in nvmet_rdma_write_data_done() local
791 struct rdma_cm_id *cm_id = rsp->queue->cm_id; in nvmet_rdma_write_data_done()
798 atomic_add(rsp->n_rdma, &queue->sq_wr_avail); in nvmet_rdma_write_data_done()
808 nvmet_rdma_error_comp(queue); in nvmet_rdma_write_data_done()
865 if (off + len > rsp->queue->dev->inline_data_size) { in nvmet_rdma_map_sgl_inline()
954 struct nvmet_rdma_queue *queue = rsp->queue; in nvmet_rdma_execute_command() local
957 &queue->sq_wr_avail) < 0)) { in nvmet_rdma_execute_command()
959 1 + rsp->n_rdma, queue->idx, in nvmet_rdma_execute_command()
960 queue->nvme_sq.ctrl->cntlid); in nvmet_rdma_execute_command()
961 atomic_add(1 + rsp->n_rdma, &queue->sq_wr_avail); in nvmet_rdma_execute_command()
966 if (rdma_rw_ctx_post(&rsp->rw, queue->qp, in nvmet_rdma_execute_command()
967 queue->cm_id->port_num, &rsp->read_cqe, NULL)) in nvmet_rdma_execute_command()
976 static void nvmet_rdma_handle_command(struct nvmet_rdma_queue *queue, in nvmet_rdma_handle_command() argument
981 ib_dma_sync_single_for_cpu(queue->dev->device, in nvmet_rdma_handle_command()
984 ib_dma_sync_single_for_cpu(queue->dev->device, in nvmet_rdma_handle_command()
988 if (!nvmet_req_init(&cmd->req, &queue->nvme_cq, in nvmet_rdma_handle_command()
989 &queue->nvme_sq, &nvmet_rdma_ops)) in nvmet_rdma_handle_command()
997 spin_lock(&queue->rsp_wr_wait_lock); in nvmet_rdma_handle_command()
998 list_add_tail(&cmd->wait_list, &queue->rsp_wr_wait_list); in nvmet_rdma_handle_command()
999 spin_unlock(&queue->rsp_wr_wait_lock); in nvmet_rdma_handle_command()
1012 struct nvmet_rdma_queue *queue = wc->qp->qp_context; in nvmet_rdma_recv_done() local
1020 nvmet_rdma_error_comp(queue); in nvmet_rdma_recv_done()
1027 nvmet_rdma_error_comp(queue); in nvmet_rdma_recv_done()
1031 cmd->queue = queue; in nvmet_rdma_recv_done()
1032 rsp = nvmet_rdma_get_rsp(queue); in nvmet_rdma_recv_done()
1039 nvmet_rdma_post_recv(queue->dev, cmd); in nvmet_rdma_recv_done()
1042 rsp->queue = queue; in nvmet_rdma_recv_done()
1046 rsp->req.port = queue->port; in nvmet_rdma_recv_done()
1049 if (unlikely(queue->state != NVMET_RDMA_Q_LIVE)) { in nvmet_rdma_recv_done()
1052 spin_lock_irqsave(&queue->state_lock, flags); in nvmet_rdma_recv_done()
1053 if (queue->state == NVMET_RDMA_Q_CONNECTING) in nvmet_rdma_recv_done()
1054 list_add_tail(&rsp->wait_list, &queue->rsp_wait_list); in nvmet_rdma_recv_done()
1057 spin_unlock_irqrestore(&queue->state_lock, flags); in nvmet_rdma_recv_done()
1061 nvmet_rdma_handle_command(queue, rsp); in nvmet_rdma_recv_done()
1259 static int nvmet_rdma_create_queue_ib(struct nvmet_rdma_queue *queue) in nvmet_rdma_create_queue_ib() argument
1262 struct nvmet_rdma_device *ndev = queue->dev; in nvmet_rdma_create_queue_ib()
1268 nr_cqe = queue->recv_queue_size + 2 * queue->send_queue_size; in nvmet_rdma_create_queue_ib()
1270 queue->cq = ib_cq_pool_get(ndev->device, nr_cqe + 1, in nvmet_rdma_create_queue_ib()
1271 queue->comp_vector, IB_POLL_WORKQUEUE); in nvmet_rdma_create_queue_ib()
1272 if (IS_ERR(queue->cq)) { in nvmet_rdma_create_queue_ib()
1273 ret = PTR_ERR(queue->cq); in nvmet_rdma_create_queue_ib()
1279 qp_attr.qp_context = queue; in nvmet_rdma_create_queue_ib()
1281 qp_attr.send_cq = queue->cq; in nvmet_rdma_create_queue_ib()
1282 qp_attr.recv_cq = queue->cq; in nvmet_rdma_create_queue_ib()
1286 qp_attr.cap.max_send_wr = queue->send_queue_size + 1; in nvmet_rdma_create_queue_ib()
1287 factor = rdma_rw_mr_factor(ndev->device, queue->cm_id->port_num, in nvmet_rdma_create_queue_ib()
1289 qp_attr.cap.max_rdma_ctxs = queue->send_queue_size * factor; in nvmet_rdma_create_queue_ib()
1293 if (queue->nsrq) { in nvmet_rdma_create_queue_ib()
1294 qp_attr.srq = queue->nsrq->srq; in nvmet_rdma_create_queue_ib()
1297 qp_attr.cap.max_recv_wr = 1 + queue->recv_queue_size; in nvmet_rdma_create_queue_ib()
1301 if (queue->port->pi_enable && queue->host_qid) in nvmet_rdma_create_queue_ib()
1304 ret = rdma_create_qp(queue->cm_id, ndev->pd, &qp_attr); in nvmet_rdma_create_queue_ib()
1309 queue->qp = queue->cm_id->qp; in nvmet_rdma_create_queue_ib()
1311 atomic_set(&queue->sq_wr_avail, qp_attr.cap.max_send_wr); in nvmet_rdma_create_queue_ib()
1314 __func__, queue->cq->cqe, qp_attr.cap.max_send_sge, in nvmet_rdma_create_queue_ib()
1315 qp_attr.cap.max_send_wr, queue->cm_id); in nvmet_rdma_create_queue_ib()
1317 if (!queue->nsrq) { in nvmet_rdma_create_queue_ib()
1318 for (i = 0; i < queue->recv_queue_size; i++) { in nvmet_rdma_create_queue_ib()
1319 queue->cmds[i].queue = queue; in nvmet_rdma_create_queue_ib()
1320 ret = nvmet_rdma_post_recv(ndev, &queue->cmds[i]); in nvmet_rdma_create_queue_ib()
1330 rdma_destroy_qp(queue->cm_id); in nvmet_rdma_create_queue_ib()
1332 ib_cq_pool_put(queue->cq, nr_cqe + 1); in nvmet_rdma_create_queue_ib()
1336 static void nvmet_rdma_destroy_queue_ib(struct nvmet_rdma_queue *queue) in nvmet_rdma_destroy_queue_ib() argument
1338 ib_drain_qp(queue->qp); in nvmet_rdma_destroy_queue_ib()
1339 if (queue->cm_id) in nvmet_rdma_destroy_queue_ib()
1340 rdma_destroy_id(queue->cm_id); in nvmet_rdma_destroy_queue_ib()
1341 ib_destroy_qp(queue->qp); in nvmet_rdma_destroy_queue_ib()
1342 ib_cq_pool_put(queue->cq, queue->recv_queue_size + 2 * in nvmet_rdma_destroy_queue_ib()
1343 queue->send_queue_size + 1); in nvmet_rdma_destroy_queue_ib()
1346 static void nvmet_rdma_free_queue(struct nvmet_rdma_queue *queue) in nvmet_rdma_free_queue() argument
1348 pr_debug("freeing queue %d\n", queue->idx); in nvmet_rdma_free_queue()
1350 nvmet_sq_destroy(&queue->nvme_sq); in nvmet_rdma_free_queue()
1352 nvmet_rdma_destroy_queue_ib(queue); in nvmet_rdma_free_queue()
1353 if (!queue->nsrq) { in nvmet_rdma_free_queue()
1354 nvmet_rdma_free_cmds(queue->dev, queue->cmds, in nvmet_rdma_free_queue()
1355 queue->recv_queue_size, in nvmet_rdma_free_queue()
1356 !queue->host_qid); in nvmet_rdma_free_queue()
1358 nvmet_rdma_free_rsps(queue); in nvmet_rdma_free_queue()
1359 ida_free(&nvmet_rdma_queue_ida, queue->idx); in nvmet_rdma_free_queue()
1360 kfree(queue); in nvmet_rdma_free_queue()
1365 struct nvmet_rdma_queue *queue = in nvmet_rdma_release_queue_work() local
1367 struct nvmet_rdma_device *dev = queue->dev; in nvmet_rdma_release_queue_work()
1369 nvmet_rdma_free_queue(queue); in nvmet_rdma_release_queue_work()
1376 struct nvmet_rdma_queue *queue) in nvmet_rdma_parse_cm_connect_req() argument
1387 queue->host_qid = le16_to_cpu(req->qid); in nvmet_rdma_parse_cm_connect_req()
1393 queue->recv_queue_size = le16_to_cpu(req->hsqsize) + 1; in nvmet_rdma_parse_cm_connect_req()
1394 queue->send_queue_size = le16_to_cpu(req->hrqsize); in nvmet_rdma_parse_cm_connect_req()
1396 if (!queue->host_qid && queue->recv_queue_size > NVME_AQ_DEPTH) in nvmet_rdma_parse_cm_connect_req()
1425 struct nvmet_rdma_queue *queue; in nvmet_rdma_alloc_queue() local
1428 queue = kzalloc(sizeof(*queue), GFP_KERNEL); in nvmet_rdma_alloc_queue()
1429 if (!queue) { in nvmet_rdma_alloc_queue()
1434 ret = nvmet_sq_init(&queue->nvme_sq); in nvmet_rdma_alloc_queue()
1440 ret = nvmet_rdma_parse_cm_connect_req(&event->param.conn, queue); in nvmet_rdma_alloc_queue()
1448 INIT_WORK(&queue->release_work, nvmet_rdma_release_queue_work); in nvmet_rdma_alloc_queue()
1449 queue->dev = ndev; in nvmet_rdma_alloc_queue()
1450 queue->cm_id = cm_id; in nvmet_rdma_alloc_queue()
1451 queue->port = port->nport; in nvmet_rdma_alloc_queue()
1453 spin_lock_init(&queue->state_lock); in nvmet_rdma_alloc_queue()
1454 queue->state = NVMET_RDMA_Q_CONNECTING; in nvmet_rdma_alloc_queue()
1455 INIT_LIST_HEAD(&queue->rsp_wait_list); in nvmet_rdma_alloc_queue()
1456 INIT_LIST_HEAD(&queue->rsp_wr_wait_list); in nvmet_rdma_alloc_queue()
1457 spin_lock_init(&queue->rsp_wr_wait_lock); in nvmet_rdma_alloc_queue()
1458 INIT_LIST_HEAD(&queue->free_rsps); in nvmet_rdma_alloc_queue()
1459 spin_lock_init(&queue->rsps_lock); in nvmet_rdma_alloc_queue()
1460 INIT_LIST_HEAD(&queue->queue_list); in nvmet_rdma_alloc_queue()
1462 queue->idx = ida_alloc(&nvmet_rdma_queue_ida, GFP_KERNEL); in nvmet_rdma_alloc_queue()
1463 if (queue->idx < 0) { in nvmet_rdma_alloc_queue()
1472 queue->comp_vector = !queue->host_qid ? 0 : in nvmet_rdma_alloc_queue()
1473 queue->idx % ndev->device->num_comp_vectors; in nvmet_rdma_alloc_queue()
1476 ret = nvmet_rdma_alloc_rsps(queue); in nvmet_rdma_alloc_queue()
1483 queue->nsrq = ndev->srqs[queue->comp_vector % ndev->srq_count]; in nvmet_rdma_alloc_queue()
1485 queue->cmds = nvmet_rdma_alloc_cmds(ndev, in nvmet_rdma_alloc_queue()
1486 queue->recv_queue_size, in nvmet_rdma_alloc_queue()
1487 !queue->host_qid); in nvmet_rdma_alloc_queue()
1488 if (IS_ERR(queue->cmds)) { in nvmet_rdma_alloc_queue()
1494 ret = nvmet_rdma_create_queue_ib(queue); in nvmet_rdma_alloc_queue()
1502 return queue; in nvmet_rdma_alloc_queue()
1505 if (!queue->nsrq) { in nvmet_rdma_alloc_queue()
1506 nvmet_rdma_free_cmds(queue->dev, queue->cmds, in nvmet_rdma_alloc_queue()
1507 queue->recv_queue_size, in nvmet_rdma_alloc_queue()
1508 !queue->host_qid); in nvmet_rdma_alloc_queue()
1511 nvmet_rdma_free_rsps(queue); in nvmet_rdma_alloc_queue()
1513 ida_free(&nvmet_rdma_queue_ida, queue->idx); in nvmet_rdma_alloc_queue()
1515 nvmet_sq_destroy(&queue->nvme_sq); in nvmet_rdma_alloc_queue()
1517 kfree(queue); in nvmet_rdma_alloc_queue()
1525 struct nvmet_rdma_queue *queue = priv; in nvmet_rdma_qp_event() local
1529 rdma_notify(queue->cm_id, event->event); in nvmet_rdma_qp_event()
1533 queue); in nvmet_rdma_qp_event()
1543 struct nvmet_rdma_queue *queue, in nvmet_rdma_cm_accept() argument
1553 queue->dev->device->attrs.max_qp_init_rd_atom); in nvmet_rdma_cm_accept()
1557 priv.crqsize = cpu_to_le16(queue->recv_queue_size); in nvmet_rdma_cm_accept()
1570 struct nvmet_rdma_queue *queue; in nvmet_rdma_queue_connect() local
1579 queue = nvmet_rdma_alloc_queue(ndev, cm_id, event); in nvmet_rdma_queue_connect()
1580 if (!queue) { in nvmet_rdma_queue_connect()
1585 if (queue->host_qid == 0) { in nvmet_rdma_queue_connect()
1590 ret = nvmet_rdma_cm_accept(cm_id, queue, &event->param.conn); in nvmet_rdma_queue_connect()
1596 queue->cm_id = NULL; in nvmet_rdma_queue_connect()
1601 list_add_tail(&queue->queue_list, &nvmet_rdma_queue_list); in nvmet_rdma_queue_connect()
1607 nvmet_rdma_free_queue(queue); in nvmet_rdma_queue_connect()
1614 static void nvmet_rdma_queue_established(struct nvmet_rdma_queue *queue) in nvmet_rdma_queue_established() argument
1618 spin_lock_irqsave(&queue->state_lock, flags); in nvmet_rdma_queue_established()
1619 if (queue->state != NVMET_RDMA_Q_CONNECTING) { in nvmet_rdma_queue_established()
1623 queue->state = NVMET_RDMA_Q_LIVE; in nvmet_rdma_queue_established()
1625 while (!list_empty(&queue->rsp_wait_list)) { in nvmet_rdma_queue_established()
1628 cmd = list_first_entry(&queue->rsp_wait_list, in nvmet_rdma_queue_established()
1632 spin_unlock_irqrestore(&queue->state_lock, flags); in nvmet_rdma_queue_established()
1633 nvmet_rdma_handle_command(queue, cmd); in nvmet_rdma_queue_established()
1634 spin_lock_irqsave(&queue->state_lock, flags); in nvmet_rdma_queue_established()
1638 spin_unlock_irqrestore(&queue->state_lock, flags); in nvmet_rdma_queue_established()
1641 static void __nvmet_rdma_queue_disconnect(struct nvmet_rdma_queue *queue) in __nvmet_rdma_queue_disconnect() argument
1646 pr_debug("cm_id= %p queue->state= %d\n", queue->cm_id, queue->state); in __nvmet_rdma_queue_disconnect()
1648 spin_lock_irqsave(&queue->state_lock, flags); in __nvmet_rdma_queue_disconnect()
1649 switch (queue->state) { in __nvmet_rdma_queue_disconnect()
1651 while (!list_empty(&queue->rsp_wait_list)) { in __nvmet_rdma_queue_disconnect()
1654 rsp = list_first_entry(&queue->rsp_wait_list, in __nvmet_rdma_queue_disconnect()
1662 queue->state = NVMET_RDMA_Q_DISCONNECTING; in __nvmet_rdma_queue_disconnect()
1668 spin_unlock_irqrestore(&queue->state_lock, flags); in __nvmet_rdma_queue_disconnect()
1671 rdma_disconnect(queue->cm_id); in __nvmet_rdma_queue_disconnect()
1672 queue_work(nvmet_wq, &queue->release_work); in __nvmet_rdma_queue_disconnect()
1676 static void nvmet_rdma_queue_disconnect(struct nvmet_rdma_queue *queue) in nvmet_rdma_queue_disconnect() argument
1681 if (!list_empty(&queue->queue_list)) { in nvmet_rdma_queue_disconnect()
1682 list_del_init(&queue->queue_list); in nvmet_rdma_queue_disconnect()
1688 __nvmet_rdma_queue_disconnect(queue); in nvmet_rdma_queue_disconnect()
1692 struct nvmet_rdma_queue *queue) in nvmet_rdma_queue_connect_fail() argument
1694 WARN_ON_ONCE(queue->state != NVMET_RDMA_Q_CONNECTING); in nvmet_rdma_queue_connect_fail()
1697 if (!list_empty(&queue->queue_list)) in nvmet_rdma_queue_connect_fail()
1698 list_del_init(&queue->queue_list); in nvmet_rdma_queue_connect_fail()
1701 pr_err("failed to connect queue %d\n", queue->idx); in nvmet_rdma_queue_connect_fail()
1702 queue_work(nvmet_wq, &queue->release_work); in nvmet_rdma_queue_connect_fail()
1721 struct nvmet_rdma_queue *queue) in nvmet_rdma_device_removal() argument
1725 if (queue) { in nvmet_rdma_device_removal()
1755 struct nvmet_rdma_queue *queue = NULL; in nvmet_rdma_cm_handler() local
1759 queue = cm_id->qp->qp_context; in nvmet_rdma_cm_handler()
1770 nvmet_rdma_queue_established(queue); in nvmet_rdma_cm_handler()
1773 if (!queue) { in nvmet_rdma_cm_handler()
1782 nvmet_rdma_queue_disconnect(queue); in nvmet_rdma_cm_handler()
1785 ret = nvmet_rdma_device_removal(cm_id, queue); in nvmet_rdma_cm_handler()
1793 nvmet_rdma_queue_connect_fail(cm_id, queue); in nvmet_rdma_cm_handler()
1806 struct nvmet_rdma_queue *queue; in nvmet_rdma_delete_ctrl() local
1810 list_for_each_entry(queue, &nvmet_rdma_queue_list, queue_list) { in nvmet_rdma_delete_ctrl()
1811 if (queue->nvme_sq.ctrl == ctrl) { in nvmet_rdma_delete_ctrl()
1812 list_del_init(&queue->queue_list); in nvmet_rdma_delete_ctrl()
1815 __nvmet_rdma_queue_disconnect(queue); in nvmet_rdma_delete_ctrl()
1824 struct nvmet_rdma_queue *queue, *tmp; in nvmet_rdma_destroy_port_queues() local
1828 list_for_each_entry_safe(queue, tmp, &nvmet_rdma_queue_list, in nvmet_rdma_destroy_port_queues()
1830 if (queue->port != nport) in nvmet_rdma_destroy_port_queues()
1833 list_del_init(&queue->queue_list); in nvmet_rdma_destroy_port_queues()
1834 __nvmet_rdma_queue_disconnect(queue); in nvmet_rdma_destroy_port_queues()
1987 struct rdma_cm_id *req_cm_id = rsp->queue->cm_id; in nvmet_rdma_disc_port_addr()
2024 struct nvmet_rdma_queue *queue, *tmp; in nvmet_rdma_remove_one() local
2045 list_for_each_entry_safe(queue, tmp, &nvmet_rdma_queue_list, in nvmet_rdma_remove_one()
2047 if (queue->dev->device != ib_device) in nvmet_rdma_remove_one()
2050 pr_info("Removing queue %d\n", queue->idx); in nvmet_rdma_remove_one()
2051 list_del_init(&queue->queue_list); in nvmet_rdma_remove_one()
2052 __nvmet_rdma_queue_disconnect(queue); in nvmet_rdma_remove_one()