Lines Matching refs:iser_task
51 struct iscsi_iser_task *iser_task = task->dd_data; in iser_prepare_read_cmd() local
54 struct iser_ctrl *hdr = &iser_task->desc.iser_header; in iser_prepare_read_cmd()
56 err = iser_dma_map_task_data(iser_task, in iser_prepare_read_cmd()
62 err = iser_reg_mem_fastreg(iser_task, ISER_DIR_IN, false); in iser_prepare_read_cmd()
67 mem_reg = &iser_task->rdma_reg[ISER_DIR_IN]; in iser_prepare_read_cmd()
80 iser_dma_unmap_task_data(iser_task, ISER_DIR_IN, DMA_FROM_DEVICE); in iser_prepare_read_cmd()
92 struct iscsi_iser_task *iser_task = task->dd_data; in iser_prepare_write_cmd() local
95 struct iser_ctrl *hdr = &iser_task->desc.iser_header; in iser_prepare_write_cmd()
96 struct iser_data_buf *buf_out = &iser_task->data[ISER_DIR_OUT]; in iser_prepare_write_cmd()
97 struct ib_sge *tx_dsg = &iser_task->desc.tx_sg[1]; in iser_prepare_write_cmd()
99 err = iser_dma_map_task_data(iser_task, in iser_prepare_write_cmd()
105 err = iser_reg_mem_fastreg(iser_task, ISER_DIR_OUT, in iser_prepare_write_cmd()
112 mem_reg = &iser_task->rdma_reg[ISER_DIR_OUT]; in iser_prepare_write_cmd()
132 iser_task->desc.num_sge = 2; in iser_prepare_write_cmd()
138 iser_dma_unmap_task_data(iser_task, ISER_DIR_OUT, DMA_TO_DEVICE); in iser_prepare_write_cmd()
345 struct iscsi_iser_task *iser_task = task->dd_data; in iser_send_command() local
351 struct iser_tx_desc *tx_desc = &iser_task->desc; in iser_send_command()
360 data_buf = &iser_task->data[ISER_DIR_IN]; in iser_send_command()
361 prot_buf = &iser_task->prot[ISER_DIR_IN]; in iser_send_command()
363 data_buf = &iser_task->data[ISER_DIR_OUT]; in iser_send_command()
364 prot_buf = &iser_task->prot[ISER_DIR_OUT]; in iser_send_command()
395 iser_task->status = ISER_TASK_STATUS_STARTED; in iser_send_command()
416 struct iscsi_iser_task *iser_task = task->dd_data; in iser_send_data_out() local
446 mem_reg = &iser_task->rdma_reg[ISER_DIR_OUT]; in iser_send_data_out()
453 if (buf_offset + data_seg_len > iser_task->data[ISER_DIR_OUT].data_len) { in iser_send_data_out()
456 iser_task->data[ISER_DIR_OUT].data_len, itt); in iser_send_data_out()
476 struct iscsi_iser_task *iser_task = task->dd_data; in iser_send_control() local
477 struct iser_tx_desc *mdesc = &iser_task->desc; in iser_send_control()
610 struct iscsi_iser_task *iser_task = task->dd_data; in iser_check_remote_inv() local
613 if (iser_task->dir[ISER_DIR_IN]) { in iser_check_remote_inv()
614 desc = iser_task->rdma_reg[ISER_DIR_IN].desc; in iser_check_remote_inv()
619 if (iser_task->dir[ISER_DIR_OUT]) { in iser_check_remote_inv()
620 desc = iser_task->rdma_reg[ISER_DIR_OUT].desc; in iser_check_remote_inv()
710 void iser_task_rdma_init(struct iscsi_iser_task *iser_task) in iser_task_rdma_init() argument
713 iser_task->status = ISER_TASK_STATUS_INIT; in iser_task_rdma_init()
715 iser_task->dir[ISER_DIR_IN] = 0; in iser_task_rdma_init()
716 iser_task->dir[ISER_DIR_OUT] = 0; in iser_task_rdma_init()
718 iser_task->data[ISER_DIR_IN].data_len = 0; in iser_task_rdma_init()
719 iser_task->data[ISER_DIR_OUT].data_len = 0; in iser_task_rdma_init()
721 iser_task->prot[ISER_DIR_IN].data_len = 0; in iser_task_rdma_init()
722 iser_task->prot[ISER_DIR_OUT].data_len = 0; in iser_task_rdma_init()
724 iser_task->prot[ISER_DIR_IN].dma_nents = 0; in iser_task_rdma_init()
725 iser_task->prot[ISER_DIR_OUT].dma_nents = 0; in iser_task_rdma_init()
727 memset(&iser_task->rdma_reg[ISER_DIR_IN], 0, in iser_task_rdma_init()
729 memset(&iser_task->rdma_reg[ISER_DIR_OUT], 0, in iser_task_rdma_init()
733 void iser_task_rdma_finalize(struct iscsi_iser_task *iser_task) in iser_task_rdma_finalize() argument
736 if (iser_task->dir[ISER_DIR_IN]) { in iser_task_rdma_finalize()
737 iser_unreg_mem_fastreg(iser_task, ISER_DIR_IN); in iser_task_rdma_finalize()
738 iser_dma_unmap_task_data(iser_task, ISER_DIR_IN, in iser_task_rdma_finalize()
742 if (iser_task->dir[ISER_DIR_OUT]) { in iser_task_rdma_finalize()
743 iser_unreg_mem_fastreg(iser_task, ISER_DIR_OUT); in iser_task_rdma_finalize()
744 iser_dma_unmap_task_data(iser_task, ISER_DIR_OUT, in iser_task_rdma_finalize()