- To: Tejun Heo <htejun@xxxxxxxxx>, IDE/ATA development list <linux-ide@xxxxxxxxxxxxxxx>
- Subject: ata_eh_link_autopsy: Bug?
- From: Mark Lord <kernel@xxxxxxxxxxxx>
- Date: Tue, 01 May 2012 16:12:46 -0400
- List-id: <linux-ide.vger.kernel.org>
- User-agent: Mozilla/5.0 (X11; Linux i686; rv:11.0) Gecko/20120327 Thunderbird/11.0.1
In libata-eh.c, the function ata_eh_link_autopsy() tries to decide
if an operation is worth retrying.
I notice that for MEDIA ERRORs, it always sits there for minutes
doing futile retries, when it's pretty obvious that the drive
is reporting an uncorrectable error.
Is this code correct?
/* determine whether the command is worth retrying */
if (qc->flags & ATA_QCFLAG_IO ||
(!(qc->err_mask & AC_ERR_INVALID) &&
qc->err_mask != AC_ERR_DEV))
qc->flags |= ATA_QCFLAG_RETRY;
I think this part may be incorrect: qc->err_mask != AC_ERR_DEV
Shouldn't that test be this instead: !(qc->err_mask & AC_ERR_DEV) ??
The mask is just about never exactly equal to AC_ERR_DEV.
In the case of a media error, it is (AC_ERR_DEV | AC_ERR_MEDIA) at this point.
Tejun?
--
To unsubscribe from this list: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
[Linux Filesystems]
[Linux SCSI]
[Linux RAID]
[Git]
[Kernel Newbies]
[Linux Newbie]
[Share Photos]
[Security]
[Netfilter]
[Bugtraq]
[Photo]
[Yosemite]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Samba]
[Video 4 Linux]
[Device Mapper]
[Linux Resources]