aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/target/target_core_xcopy.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/target/target_core_xcopy.c')
-rw-r--r--drivers/target/target_core_xcopy.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/target/target_core_xcopy.c b/drivers/target/target_core_xcopy.c
index 4515f52546f8..47fe94ee10b8 100644
--- a/drivers/target/target_core_xcopy.c
+++ b/drivers/target/target_core_xcopy.c
@@ -450,6 +450,8 @@ int target_xcopy_setup_pt(void)
450 memset(&xcopy_pt_sess, 0, sizeof(struct se_session)); 450 memset(&xcopy_pt_sess, 0, sizeof(struct se_session));
451 INIT_LIST_HEAD(&xcopy_pt_sess.sess_list); 451 INIT_LIST_HEAD(&xcopy_pt_sess.sess_list);
452 INIT_LIST_HEAD(&xcopy_pt_sess.sess_acl_list); 452 INIT_LIST_HEAD(&xcopy_pt_sess.sess_acl_list);
453 INIT_LIST_HEAD(&xcopy_pt_sess.sess_cmd_list);
454 spin_lock_init(&xcopy_pt_sess.sess_cmd_lock);
453 455
454 xcopy_pt_nacl.se_tpg = &xcopy_pt_tpg; 456 xcopy_pt_nacl.se_tpg = &xcopy_pt_tpg;
455 xcopy_pt_nacl.nacl_sess = &xcopy_pt_sess; 457 xcopy_pt_nacl.nacl_sess = &xcopy_pt_sess;
@@ -644,7 +646,7 @@ static int target_xcopy_read_source(
644 pr_debug("XCOPY: Built READ_16: LBA: %llu Sectors: %u Length: %u\n", 646 pr_debug("XCOPY: Built READ_16: LBA: %llu Sectors: %u Length: %u\n",
645 (unsigned long long)src_lba, src_sectors, length); 647 (unsigned long long)src_lba, src_sectors, length);
646 648
647 transport_init_se_cmd(se_cmd, &xcopy_pt_tfo, NULL, length, 649 transport_init_se_cmd(se_cmd, &xcopy_pt_tfo, &xcopy_pt_sess, length,
648 DMA_FROM_DEVICE, 0, &xpt_cmd->sense_buffer[0]); 650 DMA_FROM_DEVICE, 0, &xpt_cmd->sense_buffer[0]);
649 xop->src_pt_cmd = xpt_cmd; 651 xop->src_pt_cmd = xpt_cmd;
650 652
@@ -704,7 +706,7 @@ static int target_xcopy_write_destination(
704 pr_debug("XCOPY: Built WRITE_16: LBA: %llu Sectors: %u Length: %u\n", 706 pr_debug("XCOPY: Built WRITE_16: LBA: %llu Sectors: %u Length: %u\n",
705 (unsigned long long)dst_lba, dst_sectors, length); 707 (unsigned long long)dst_lba, dst_sectors, length);
706 708
707 transport_init_se_cmd(se_cmd, &xcopy_pt_tfo, NULL, length, 709 transport_init_se_cmd(se_cmd, &xcopy_pt_tfo, &xcopy_pt_sess, length,
708 DMA_TO_DEVICE, 0, &xpt_cmd->sense_buffer[0]); 710 DMA_TO_DEVICE, 0, &xpt_cmd->sense_buffer[0]);
709 xop->dst_pt_cmd = xpt_cmd; 711 xop->dst_pt_cmd = xpt_cmd;
710 712