From: Paolo Bonzini <pbonzini@redhat.com>
To: linux-scsi <linux-scsi@vger.kernel.org>
Subject: Why are DID_ABORT and TASK_ABORTED handled differently?
Date: Thu, 12 Jul 2012 18:49:55 +0200 [thread overview]
Message-ID: <4FFF0033.2090902@redhat.com> (raw)
Currently, DID_ABORT relays the failure to the upper layer, while TASK
ABORTED (after the suggestion at
http://marc.info/?l=linux-scsi&m=121932916906009&w=2 was implemented)
retries the command.
Is it correct that when TAS=0 an aborted task (from TMF, persistent
reservation or anything else) can result in DID_ABORT? There are some
clues of this in the drivers, but on the other hand scsi-debug has a
very strange usage of DID_ABORT:
static const int illegal_condition_result =
(DRIVER_SENSE << 24) | (DID_ABORT << 16) |
SAM_STAT_CHECK_CONDITION;
...
/* DIX + T10 DIF */
if (scsi_debug_dix && scsi_prot_sg_count(SCpnt)) {
int prot_ret = prot_verify_read(SCpnt, lba, num, ei_lba);
if (prot_ret) {
mk_sense_buffer(devip, ABORTED_COMMAND, 0x10,
prot_ret);
return illegal_condition_result;
}
}
If it is the case that they are similar, is there any reason why the two
are handled differently?
Paolo
next reply other threads:[~2012-07-12 16:49 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-12 16:49 Paolo Bonzini [this message]
2012-07-12 17:09 ` Why are DID_ABORT and TASK_ABORTED handled differently? James Bottomley
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=4FFF0033.2090902@redhat.com \
--to=pbonzini@redhat.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.