summaryrefslogtreecommitdiff
path: root/usr/src
diff options
context:
space:
mode:
authorSrikanth Suravajhala <srikanth.suravajhala@oracle.com>2010-07-29 12:16:10 -0700
committerSrikanth Suravajhala <srikanth.suravajhala@oracle.com>2010-07-29 12:16:10 -0700
commit8c55a9c0f9c033a6f28a7dfe6443392d1a7a5691 (patch)
tree54bb8a0ebb4a08d974fbe310fffd364bfdc02f0d /usr/src
parent9240226574c5b04eff5ae3e7b26437064c01d721 (diff)
downloadillumos-joyent-8c55a9c0f9c033a6f28a7dfe6443392d1a7a5691.tar.gz
6952406 enumeration errors and disk failures during boot
Diffstat (limited to 'usr/src')
-rw-r--r--usr/src/uts/common/io/scsi/conf/scsi_confsubr.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/usr/src/uts/common/io/scsi/conf/scsi_confsubr.c b/usr/src/uts/common/io/scsi/conf/scsi_confsubr.c
index 1b2dc7ab52..2e14ca4ff9 100644
--- a/usr/src/uts/common/io/scsi/conf/scsi_confsubr.c
+++ b/usr/src/uts/common/io/scsi/conf/scsi_confsubr.c
@@ -1023,7 +1023,7 @@ scsi_test(struct scsi_pkt *pkt, enum scsi_test_ctxt ctxt)
int
scsi_probe(struct scsi_device *sd, int (*callback)())
{
- int ret;
+ int ret, retry = 0;
scsi_hba_tran_t *tran = sd->sd_address.a_hba_tran;
if (scsi_check_ss2_LUN_limit(sd) != 0) {
@@ -1033,13 +1033,21 @@ scsi_probe(struct scsi_device *sd, int (*callback)())
*/
return (SCSIPROBE_NORESP); /* skip probing this one */
}
-
+again:
if (tran->tran_tgt_probe != NULL) {
ret = (*tran->tran_tgt_probe)(sd, callback);
} else {
ret = scsi_hba_probe(sd, callback);
}
+ if ((ret != SCSIPROBE_EXISTS) && (retry == 0)) {
+ if (scsi_reset(&sd->sd_address, RESET_LUN) != 1) {
+ cmn_err(CE_WARN, "scsi_probe: scsi_reset failed");
+ }
+ retry = 1;
+ goto again;
+ }
+
if (ret == SCSIPROBE_EXISTS) {
create_inquiry_props(sd);
/* is this a strictly-SCSI-2 node ?? */