summaryrefslogtreecommitdiffstats
path: root/drivers/target/target_core_pscsi.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@infradead.org>2012-05-20 11:59:11 -0400
committerNicholas Bellinger <nab@linux-iscsi.org>2012-06-12 17:49:58 -0700
commit061b7ac87e3d38010b9ef540d41fc71c46b7d656 (patch)
tree132e62739e7ea1950ece33c504301fb25c4d2d21 /drivers/target/target_core_pscsi.c
parentcc5ab6df130b2cefc274ef2c5c92afee5a0b091e (diff)
downloadlinux-061b7ac87e3d38010b9ef540d41fc71c46b7d656.tar.gz
linux-061b7ac87e3d38010b9ef540d41fc71c46b7d656.tar.xz
linux-061b7ac87e3d38010b9ef540d41fc71c46b7d656.zip
target: remove control CDB flags
We don't need three flags to classifiy the CDB as we can check for a NULL S/G list for a dataless command, and can infer from the absence of the data flag that we deal with a control CDB. Also remove the _SG_IO from the data CDB flag as all I/O is dont on S/G lists now. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Diffstat (limited to 'drivers/target/target_core_pscsi.c')
-rw-r--r--drivers/target/target_core_pscsi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/target/target_core_pscsi.c b/drivers/target/target_core_pscsi.c
index 4ce2cf642fce..bfc72327370c 100644
--- a/drivers/target/target_core_pscsi.c
+++ b/drivers/target/target_core_pscsi.c
@@ -1042,7 +1042,7 @@ static int pscsi_execute_cmd(struct se_cmd *cmd, struct scatterlist *sgl,
memcpy(pt->pscsi_cdb, cmd->t_task_cdb,
scsi_command_size(cmd->t_task_cdb));
- if (cmd->se_cmd_flags & SCF_SCSI_NON_DATA_CDB) {
+ if (!sgl) {
req = blk_get_request(pdv->pdv_sd->request_queue,
(data_direction == DMA_TO_DEVICE),
GFP_KERNEL);