Re: [PATCH 23/25] scsi: sd: handle read/write CDL timeout failures

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 12/9/22 09:13, Mike Christie wrote:
>> @@ -595,6 +596,22 @@ enum scsi_disposition scsi_check_sense(struct scsi_cmnd *scmd)
>>  		if (sshdr.asc == 0x10) /* DIF */
>>  			return SUCCESS;
>>  
>> +		/*
>> +		 * Check aborts due to command duration limit policy:
>> +		 * ABORTED COMMAND additional sense code with the
>> +		 * COMMAND TIMEOUT BEFORE PROCESSING or
>> +		 * COMMAND TIMEOUT DURING PROCESSING or
>> +		 * COMMAND TIMEOUT DURING PROCESSING DUE TO ERROR RECOVERY
>> +		 * additional sense code qualifiers.
>> +		 */
>> +		if (sshdr.asc == 0x2e &&
>> +		    sshdr.ascq >= 0x01 && sshdr.ascq <= 0x03) {
>> +			set_scsi_ml_byte(scmd, SCSIML_STAT_DL_TIMEOUT);
>> +			req->cmd_flags |= REQ_FAILFAST_DEV;
> 
> Why are you setting the REQ_FAILFAST_DEV bit? Does libata check for it?
> 
> I thought you might have set it because DID_TIME_OUT was set and you wanted
> to hit that check in scsi_noretry_cmd. However, I see that patch where you
> added the new flag so DID_TIME_OUT does not get set sometimes so you probably
> don't hit that path, and you have that check for SCSIML_STAT_DL_TIMEOUT in there
> below.

This is for the block layer (blk_noretry_request() helper) so that the
remainder of the request is not retried. Retrying a CDL command that
timedout goes against the goal of CDL.



-- 
Damien Le Moal
Western Digital Research




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux