From: Hannes Reinecke <hare@suse.de>
To: SCSI Mailing List <linux-scsi@vger.kernel.org>
Subject: [PATCH] Retry INQUIRY on power-on
Date: Fri, 31 Mar 2006 15:12:01 +0200 [thread overview]
Message-ID: <442D2AA1.3070909@suse.de> (raw)
[-- Attachment #1: Type: text/plain, Size: 594 bytes --]
Hi all,
the current inquiry code in scsi_scan.c:scsi_probe_lun() will retry the
inquiry only for ASC/ASCQ 0x28/0x0 and 0x29/0x0. When I'm hot-plugging a
disk no reset has necessarily happened, so the first rescan will fail.
The disk is found properly on the second rescan.
So we really should loosen that statement to do retry for all ASC 0x29
values as a power-on might well have occured without a reset.
Please apply.
Cheers,
Hannes
--
Dr. Hannes Reinecke hare@suse.de
SuSE Linux Products GmbH S390 & zSeries
Maxfeldstraße 5 +49 911 74053 688
90409 Nürnberg http://www.suse.de
[-- Attachment #2: scsi-scan-retry-on-poweron --]
[-- Type: text/plain, Size: 850 bytes --]
From: Hannes Reinecke <hare@suse.de>
Subject: Retry INQUIRY on power-on
The current code retries INQUIRY only for ASC/ASCQ 0x29/0x0
(POWER ON, RESET, OR BUS DEVICE RESET OCCURRED). This means drives
which have been hot-removed (ie without a reset) won't be detected
upon rescan. So we should loose this condition to enable a retry
for the ASC 0x29 in general.
Signed-off-by: Hannes Reinecke
diff --git a/drivers/scsi/scsi_scan.c b/drivers/scsi/scsi_scan.c
index f149459..f6ead5c 100644
--- a/drivers/scsi/scsi_scan.c
+++ b/drivers/scsi/scsi_scan.c
@@ -514,8 +514,7 @@ static int scsi_probe_lun(struct scsi_de
scsi_sense_valid(&sshdr)) {
if ((sshdr.sense_key == UNIT_ATTENTION) &&
((sshdr.asc == 0x28) ||
- (sshdr.asc == 0x29)) &&
- (sshdr.ascq == 0))
+ (sshdr.asc == 0x29)))
continue;
}
}
next reply other threads:[~2006-03-31 13:12 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-03-31 13:12 Hannes Reinecke [this message]
2006-03-31 15:16 ` [PATCH] Retry INQUIRY on power-on James Bottomley
2006-04-03 6:47 ` Hannes Reinecke
2006-04-03 17:37 ` Mike Christie
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=442D2AA1.3070909@suse.de \
--to=hare@suse.de \
--cc=linux-scsi@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.