提交 fd1b494d 编写于 作者: L Luben Tuikov 提交者: James Bottomley

[SCSI] Fix sense key MEDIUM ERROR processing and retry

1) If the device reports an uncorrectable MEDIUM ERROR, such
as SK MEDIUM ERROR, ASC UNRECOVERED READ ERR, AMNF DATA
FIELD or RECORD NOT FOUND, then: In scsi_check_sense()
return SUCCESS so as to not retry -- the error is
uncorrectable -- this speeds up total processing time.
Signed-off-by: NLuben Tuikov <ltuikov@yahoo.com>

Extracted the MEDIUM ERROR piece and
Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
上级 7b3b9211
......@@ -359,6 +359,11 @@ static int scsi_check_sense(struct scsi_cmnd *scmd)
return SUCCESS;
case MEDIUM_ERROR:
if (sshdr.asc == 0x11 || /* UNRECOVERED READ ERR */
sshdr.asc == 0x13 || /* AMNF DATA FIELD */
sshdr.asc == 0x14) { /* RECORD NOT FOUND */
return SUCCESS;
}
return NEEDS_RETRY;
case HARDWARE_ERROR:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册