Skip to content

Commit

Permalink
[SCSI] libfc: use DID_TRANSPORT_DISRUPTED while lport not ready
Browse files Browse the repository at this point in the history
This is per Mile Christie feedback since in this case IO
could get retried for tape devices and therefore DID_REQUEUE
cannot be used, more details in this thread.

http://marc.info/?l=linux-scsi&m=127970522630136&w=2

Signed-off-by: Vasu Dev <vasu.dev@intel.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
  • Loading branch information
Vasu Dev authored and James Bottomley committed Oct 25, 2010
1 parent 73b4376 commit 75eee72
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions drivers/scsi/libfc/fc_fcp.c
Original file line number Diff line number Diff line change
Expand Up @@ -1971,10 +1971,8 @@ static void fc_io_compl(struct fc_fcp_pkt *fsp)
break;
}

if (lport->state != LPORT_ST_READY && fsp->status_code != FC_COMPLETE) {
sc_cmd->result = (DID_REQUEUE << 16);
FC_FCP_DBG(fsp, "Returning DID_REQUEUE to scsi-ml\n");
}
if (lport->state != LPORT_ST_READY && fsp->status_code != FC_COMPLETE)
sc_cmd->result = (DID_TRANSPORT_DISRUPTED << 16);

spin_lock_irqsave(&si->scsi_queue_lock, flags);
list_del(&fsp->list);
Expand Down

0 comments on commit 75eee72

Please sign in to comment.