aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi
diff options
context:
space:
mode:
authorMike Christie <michaelc@cs.wisc.edu>2008-08-19 19:45:26 -0400
committerJames Bottomley <James.Bottomley@HansenPartnership.com>2008-10-13 09:28:49 -0400
commit56d7fcfa815564b40a1b0ec7a30ea8cb3bc0713e (patch)
tree29ad7384a0f2ba5793f6d90d66daee52825f29a8 /drivers/scsi
parenta4dfaa6f2e55b736adf2719133996f7e7dc309bc (diff)
[SCSI] iscsi class, libiscsi and qla4xxx: convert to new transport host byte values
This patch converts the iscsi drivers to the new host byte values. v2 Drop some conversions. Want to avoid conflicts with other patches. v1 initial patch. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/scsi')
-rw-r--r--drivers/scsi/libiscsi.c8
-rw-r--r--drivers/scsi/qla4xxx/ql4_isr.c4
-rw-r--r--drivers/scsi/scsi_transport_iscsi.c4
3 files changed, 9 insertions, 7 deletions
diff --git a/drivers/scsi/libiscsi.c b/drivers/scsi/libiscsi.c
index 521dbf7e521d..0e8f26baca6e 100644
--- a/drivers/scsi/libiscsi.c
+++ b/drivers/scsi/libiscsi.c
@@ -1200,7 +1200,7 @@ int iscsi_queuecommand(struct scsi_cmnd *sc, void (*done)(struct scsi_cmnd *))
1200 goto reject; 1200 goto reject;
1201 case ISCSI_STATE_RECOVERY_FAILED: 1201 case ISCSI_STATE_RECOVERY_FAILED:
1202 reason = FAILURE_SESSION_RECOVERY_TIMEOUT; 1202 reason = FAILURE_SESSION_RECOVERY_TIMEOUT;
1203 sc->result = DID_NO_CONNECT << 16; 1203 sc->result = DID_TRANSPORT_FAILFAST << 16;
1204 break; 1204 break;
1205 case ISCSI_STATE_TERMINATE: 1205 case ISCSI_STATE_TERMINATE:
1206 reason = FAILURE_SESSION_TERMINATE; 1206 reason = FAILURE_SESSION_TERMINATE;
@@ -2333,8 +2333,10 @@ static void iscsi_start_session_recovery(struct iscsi_session *session,
2333 * flush queues. 2333 * flush queues.
2334 */ 2334 */
2335 spin_lock_bh(&session->lock); 2335 spin_lock_bh(&session->lock);
2336 fail_all_commands(conn, -1, 2336 if (STOP_CONN_RECOVER)
2337 STOP_CONN_RECOVER ? DID_BUS_BUSY : DID_ERROR); 2337 fail_all_commands(conn, -1, DID_TRANSPORT_DISRUPTED);
2338 else
2339 fail_all_commands(conn, -1, DID_ERROR);
2338 flush_control_queues(session, conn); 2340 flush_control_queues(session, conn);
2339 spin_unlock_bh(&session->lock); 2341 spin_unlock_bh(&session->lock);
2340 mutex_unlock(&session->eh_mutex); 2342 mutex_unlock(&session->eh_mutex);
diff --git a/drivers/scsi/qla4xxx/ql4_isr.c b/drivers/scsi/qla4xxx/ql4_isr.c
index a91a57c57bff..799120fcb9be 100644
--- a/drivers/scsi/qla4xxx/ql4_isr.c
+++ b/drivers/scsi/qla4xxx/ql4_isr.c
@@ -139,7 +139,7 @@ static void qla4xxx_status_entry(struct scsi_qla_host *ha,
139 ha->host_no, cmd->device->channel, 139 ha->host_no, cmd->device->channel,
140 cmd->device->id, cmd->device->lun)); 140 cmd->device->id, cmd->device->lun));
141 141
142 cmd->result = DID_BUS_BUSY << 16; 142 cmd->result = DID_TRANSPORT_DISRUPTED << 16;
143 143
144 /* 144 /*
145 * Mark device missing so that we won't continue to send 145 * Mark device missing so that we won't continue to send
@@ -243,7 +243,7 @@ static void qla4xxx_status_entry(struct scsi_qla_host *ha,
243 if (atomic_read(&ddb_entry->state) == DDB_STATE_ONLINE) 243 if (atomic_read(&ddb_entry->state) == DDB_STATE_ONLINE)
244 qla4xxx_mark_device_missing(ha, ddb_entry); 244 qla4xxx_mark_device_missing(ha, ddb_entry);
245 245
246 cmd->result = DID_BUS_BUSY << 16; 246 cmd->result = DID_TRANSPORT_DISRUPTED << 16;
247 break; 247 break;
248 248
249 case SCS_QUEUE_FULL: 249 case SCS_QUEUE_FULL:
diff --git a/drivers/scsi/scsi_transport_iscsi.c b/drivers/scsi/scsi_transport_iscsi.c
index 0ce5f7cdfe2a..cbaae48f47ed 100644
--- a/drivers/scsi/scsi_transport_iscsi.c
+++ b/drivers/scsi/scsi_transport_iscsi.c
@@ -374,10 +374,10 @@ int iscsi_session_chkready(struct iscsi_cls_session *session)
374 err = 0; 374 err = 0;
375 break; 375 break;
376 case ISCSI_SESSION_FAILED: 376 case ISCSI_SESSION_FAILED:
377 err = DID_IMM_RETRY << 16; 377 err = DID_TRANSPORT_DISRUPTED << 16;
378 break; 378 break;
379 case ISCSI_SESSION_FREE: 379 case ISCSI_SESSION_FREE:
380 err = DID_NO_CONNECT << 16; 380 err = DID_TRANSPORT_FAILFAST << 16;
381 break; 381 break;
382 default: 382 default:
383 err = DID_NO_CONNECT << 16; 383 err = DID_NO_CONNECT << 16;