[SCSI] fusion: fibre channel: return DID_ERROR for MPI_IOCSTATUS_SCSI_IOC_TERMINATED
authorEric Moore <eric.moore@lsil.com>
Fri, 5 Jan 2007 03:44:01 +0000 (20:44 -0700)
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>
Sat, 6 Jan 2007 15:22:33 +0000 (09:22 -0600)
A repost of a patch forwarded by Mikael Reed from 2006-12-20.

The fibre channel IOC may kill a request for a variety of
reasons, some of which may be recovered by a retry, some of
which are unlikely to be recovered.  Return DID_ERROR
instead of DID_RESET to permit retry of the command,
just not an infinite number of them.

Signed-off-by: Michael Reed <mdr@sgi.com>
Signed-off-by: Eric Moore <Eric.Moore@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
drivers/message/fusion/mptscsih.c

index 2c72c36b8171cd67f26114c9c2f97b4d70b0b2d6..076eb2b573a33c4baf3c664da4b6d7d0c2f55bca 100644 (file)
@@ -701,6 +701,17 @@ mptscsih_io_done(MPT_ADAPTER *ioc, MPT_FRAME_HDR *mf, MPT_FRAME_HDR *mr)
                                                break;
                                        }
                                }
+                       } else if (ioc->bus_type == FC) {
+                               /*
+                                * The FC IOC may kill a request for variety of
+                                * reasons, some of which may be recovered by a
+                                * retry, some which are unlikely to be
+                                * recovered. Return DID_ERROR instead of
+                                * DID_RESET to permit retry of the command,
+                                * just not an infinite number of them
+                                */
+                               sc->result = DID_ERROR << 16;
+                               break;
                        }
 
                        /*