From: Mike Christie <michaelc@cs.wisc.edu>
To: Hannes Reinecke <hare@suse.de>
Cc: linux-scsi@vger.kernel.org, Ilgu Hong <ilgu.hong@promise.com>
Subject: Re: [PATCH 3/3] scsi dh alua: handle report luns data changed in check sense callout
Date: Fri, 06 Feb 2009 12:04:40 -0600 [thread overview]
Message-ID: <498C7BB8.5020302@cs.wisc.edu> (raw)
In-Reply-To: <498AF0C4.7070701@suse.de>
Hannes Reinecke wrote:
> Hi Mike,
>
> michaelc@cs.wisc.edu wrote:
>> From: Ilgu Hong <ilgu.hong@promise.com>
>>
>> When we switch controllers the Intel Multi-Flex reports
>> REPORTED_LUNS_DATA_HAS_CHANGED. This patch just has us
>> retry the command.
>>
>> Signed-off-by: Ilgu Hong <ilgu.hong@promise.com>
>> Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
>> ---
>> drivers/scsi/device_handler/scsi_dh_alua.c | 9 +++++++++
>> 1 files changed, 9 insertions(+), 0 deletions(-)
>>
>> diff --git a/drivers/scsi/device_handler/scsi_dh_alua.c
>> b/drivers/scsi/device_handler/scsi_dh_alua.c
>> index 31e1df5..dba154c 100644
>> --- a/drivers/scsi/device_handler/scsi_dh_alua.c
>> +++ b/drivers/scsi/device_handler/scsi_dh_alua.c
>> @@ -461,6 +461,15 @@ static int alua_check_sense(struct scsi_device
>> *sdev,
>> */
>> return ADD_TO_MLQUEUE;
>> }
>> + if (sense_hdr->asc == 0x3f && sense_hdr->ascq == 0x0e) {
>> + /*
>> + * REPORTED_LUNS_DATA_HAS_CHANGED is reported
>> + * when switching controllers on targets like
>> + * Intel Multi-Flex. We can just retry.
>> + */
>> + return ADD_TO_MLQUEUE;
>> + }
>> +
>> break;
>> }
>>
> Hmm. We could as well always retry for Unit Attention; it's meant to be
> a temporary condition anyway so no harm in retrying.
>
Hey, do you mean you want me to just do
case UNIT_ATTENTION:
return ADD_TO_MLQUEUE;
? In scsi_error.c:scsi_check_sense we fail for
/*
* if the device is not started, we need to wake
* the error handler to start the motor
*/
if (scmd->device->allow_restart &&
(sshdr.asc == 0x04) && (sshdr.ascq == 0x02))
return FAILED;
and in scsi_lib.c:scsi_io_compeltion we fail for
if (cmd->device->removable) {
/* Detected disc change. Set a bit
* and quietly refuse further access.
*/
cmd->device->changed = 1;
scsi_end_request(cmd, -EIO, this_count, 1);
return;
next prev parent reply other threads:[~2009-02-06 18:04 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-30 23:00 [PATCH 1/3] scsi dh alua: fix group id masking michaelc
2009-01-30 23:00 ` [PATCH 2/3] scsi dh alua: add intel Multi-Flex device michaelc
2009-01-30 23:00 ` [PATCH 3/3] scsi dh alua: handle report luns data changed in check sense callout michaelc
2009-02-05 13:59 ` Hannes Reinecke
2009-02-06 18:04 ` Mike Christie [this message]
2009-02-05 13:56 ` [PATCH 2/3] scsi dh alua: add intel Multi-Flex device Hannes Reinecke
2009-02-05 13:56 ` [PATCH 1/3] scsi dh alua: fix group id masking Hannes Reinecke
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=498C7BB8.5020302@cs.wisc.edu \
--to=michaelc@cs.wisc.edu \
--cc=hare@suse.de \
--cc=ilgu.hong@promise.com \
--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.