Re: [PATCH 13/24] scsi: Kill DRIVER_SENSE

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

 



> diff --git a/drivers/scsi/megaraid/megaraid_sas_base.c b/drivers/scsi/megaraid/megaraid_sas_base.c
> index c40fbea06cc5..649f9610ca72 100644
> --- a/drivers/scsi/megaraid/megaraid_sas_base.c
> +++ b/drivers/scsi/megaraid/megaraid_sas_base.c
> @@ -1,3 +1,4 @@
> +
>  // SPDX-License-Identifier: GPL-2.0-or-later
>  /*
>   *  Linux MegaRAID driver for SAS based RAID controllers

Typo?

> index 59443e0184fd..d6ecb773c512 100644
> --- a/drivers/scsi/scsi.c
> +++ b/drivers/scsi/scsi.c
> @@ -203,8 +203,8 @@ void scsi_finish_command(struct scsi_cmnd *cmd)
>  	 * If we have valid sense information, then some kind of recovery
>  	 * must have taken place.  Make a note of this.
>  	 */
> -	if (SCSI_SENSE_VALID(cmd))
> -		cmd->result |= (DRIVER_SENSE << 24);
> +	if (SCSI_SENSE_VALID(cmd) && status_byte(cmd->result) == SAM_STAT_GOOD)
> +		set_status_byte(cmd, SAM_STAT_CHECK_CONDITION);

This means that a REQUEST SENSE command can never result in SAM_STAT_GOOD, 
right? Are there implications for higher layers?

-- 



[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