From: Jeff Garzik <jgarzik@pobox.com>
To: Mark Lord <liml@rtr.ca>
Cc: Tejun Heo <htejun@gmail.com>,
IDE/ATA development list <linux-ide@vger.kernel.org>
Subject: Re: [PATCH] libata-eh set tf flags in NCQ EH result_tf
Date: Fri, 25 Apr 2008 01:15:38 -0400 [thread overview]
Message-ID: <481168FA.5020709@pobox.com> (raw)
In-Reply-To: <480FF229.2060808@rtr.ca>
Mark Lord wrote:
> Fix mis-reporting of NCQ errors by ensuring that result_tf->flags
> is properly initialized in libata-eh. This allows ata_gen_ata_sense()
> to report the failed block number correctly to SCSI after a media error
> during NCQ.
>
> This patch may also be a candidate for backporting to earlier kernels.
> Without this fix, SCSI will fail I/O on the entire request rather
> than just the bad sector. That can be bad for a request that was
> merged from many independent read reads from different tasks.
>
> Signed-off-by: Mark Lord <mlord@pobox.com> ---
>
> This is an alternative version of the original patch
> which safely copied the outgoing tf.flags to result_tf.flags.
> Both work. Pick one.
>
> --- upstream/drivers/ata/libata-eh.c 2008-04-18 09:31:15.000000000 -0400
> +++ linux/drivers/ata/libata-eh.c 2008-04-23 16:25:38.000000000 -0400
> @@ -1402,6 +1402,7 @@
> /* we've got the perpetrator, condemn it */
> qc = __ata_qc_from_tag(ap, tag);
> memcpy(&qc->result_tf, &tf, sizeof(tf));
> + qc->result_tf.flags = ATA_TFLAG_ISADDR | ATA_TFLAG_LBA |
> ATA_TFLAG_LBA48;
> qc->err_mask |= AC_ERR_DEV | AC_ERR_NCQ;
applied this version
next prev parent reply other threads:[~2008-04-25 5:15 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-23 20:33 [PATCH] libata-eh copy result_tf flags from outgoing tf Mark Lord
2008-04-23 22:14 ` Tejun Heo
2008-04-23 23:37 ` Mark Lord
2008-04-24 1:02 ` Tejun Heo
2008-04-24 2:24 ` Mark Lord
2008-04-24 2:43 ` Tejun Heo
2008-04-24 2:36 ` Mark Lord
2008-04-24 2:42 ` Tejun Heo
2008-04-24 2:36 ` [PATCH] libata-eh set tf flags in NCQ EH result_tf Mark Lord
2008-04-24 2:43 ` Tejun Heo
2008-04-25 5:15 ` Jeff Garzik [this message]
2008-04-25 13:56 ` libata-eh/pmp command sequence on NCQ media error Mark Lord
2008-04-25 16:10 ` Tejun Heo
2008-04-25 16:34 ` Mark Lord
2008-04-30 21:33 ` Mark Lord
2008-04-30 21:40 ` Mark Lord
2008-04-30 21:52 ` Mark Lord
2008-05-01 0:51 ` Tejun Heo
2008-05-01 2:45 ` Mark Lord
2008-05-01 2:55 ` Tejun Heo
2008-05-01 3:47 ` Mark Lord
2008-05-01 11:24 ` Mark Lord
2008-05-01 12:24 ` Tejun Heo
2008-05-01 12:33 ` Mark Lord
2008-05-01 12:40 ` Tejun Heo
2008-05-01 2:48 ` Mark Lord
2008-05-01 2:54 ` Tejun Heo
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=481168FA.5020709@pobox.com \
--to=jgarzik@pobox.com \
--cc=htejun@gmail.com \
--cc=liml@rtr.ca \
--cc=linux-ide@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.