diff options
author | Nicholas Bellinger <nab@linux-iscsi.org> | 2011-07-21 04:41:48 +0000 |
---|---|---|
committer | Nicholas Bellinger <nab@linux-iscsi.org> | 2011-07-22 09:37:48 +0000 |
commit | 1d20bb6147954d4fbd337a3d1b40c7eeae254cd7 (patch) | |
tree | 23dcdd9376c5e26acfd2817812e2d5ccfbf81149 /include/target | |
parent | 6708bb27bb2703da238f21f516034263348af5be (diff) | |
download | linux-1d20bb6147954d4fbd337a3d1b40c7eeae254cd7.tar.gz linux-1d20bb6147954d4fbd337a3d1b40c7eeae254cd7.tar.bz2 linux-1d20bb6147954d4fbd337a3d1b40c7eeae254cd7.zip |
target: ->map_task_SG conversion to ->map_control_SG and ->map_data_SG
This patch breaks up the ->map_task_SG() backend call into two seperate
->map_control_SG() and ->map_data_SG() in order to better address
IBLOCK and pSCSI. IBLOCK only allocates bios for ->map_data_SG(), and
pSCSI will allocate a struct request for both cases.
This patch fixes incorrect usage of ->map_task_SG() for all se_cmd descriptors
in transport_generic_new_cmd() by moving the call into it's proper location
directly inside of transport_allocate_data_tasks()
Reported-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Diffstat (limited to 'include/target')
-rw-r--r-- | include/target/target_core_transport.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/include/target/target_core_transport.h b/include/target/target_core_transport.h index 740957655a64..54af39d8e3fb 100644 --- a/include/target/target_core_transport.h +++ b/include/target/target_core_transport.h @@ -239,9 +239,13 @@ struct se_subsystem_api { */ int (*cdb_none)(struct se_task *); /* - * For SCF_SCSI_DATA_SG_IO_CDB and SCF_SCSI_CONTROL_SG_IO_CDB + * For SCF_SCSI_DATA_SG_IO_CDB */ - int (*map_task_SG)(struct se_task *); + int (*map_data_SG)(struct se_task *); + /* + * For SCF_SCSI_CONTROL_SG_IO_CDB + */ + int (*map_control_SG)(struct se_task *); /* * attach_hba(): */ |