[SCSI] be2iscsi: decide which requests need completion
authorJayamohan Kallickal <jayamohank@serverengines.com>
Mon, 4 Jan 2010 23:39:19 +0000 (05:09 +0530)
committerJames Bottomley <James.Bottomley@suse.de>
Mon, 18 Jan 2010 16:48:22 +0000 (10:48 -0600)
This patch decides whether ack based completion is required or not

Signed-off-by: Jayamohan Kallickal <jayamohank@serverengines.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
drivers/scsi/be2iscsi/be_main.c

index 0fae26468a09b2de052e6594433d013860a87982..26d7016492da87966e9994bdb7a84b405f138d18 100644 (file)
@@ -3546,6 +3546,11 @@ static int beiscsi_mtask(struct iscsi_task *task)
                else
                        AMAP_SET_BITS(struct amap_iscsi_wrb, type, pwrb,
                                      INI_RD_CMD);
+               if (task->hdr->ttt == ISCSI_RESERVED_TAG)
+                       AMAP_SET_BITS(struct amap_iscsi_wrb, dmsg, pwrb, 0);
+               else
+                       AMAP_SET_BITS(struct amap_iscsi_wrb, dmsg, pwrb, 1);
+
                hwi_write_buffer(pwrb, task);
                break;
        case ISCSI_OP_TEXT:
@@ -3554,6 +3559,7 @@ static int beiscsi_mtask(struct iscsi_task *task)
                else
                        AMAP_SET_BITS(struct amap_iscsi_wrb, type, pwrb,
                                      INI_WR_CMD);
+               AMAP_SET_BITS(struct amap_iscsi_wrb, dmsg, pwrb, 0);
                AMAP_SET_BITS(struct amap_iscsi_wrb, dsp, pwrb, 1);
                hwi_write_buffer(pwrb, task);
                break;