lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y00xPoTeYEVkhMMl@x1-carbon>
Date:   Mon, 17 Oct 2022 10:41:03 +0000
From:   Niklas Cassel <Niklas.Cassel@....com>
To:     John Garry <john.garry@...wei.com>
CC:     "jejb@...ux.ibm.com" <jejb@...ux.ibm.com>,
        "martin.petersen@...cle.com" <martin.petersen@...cle.com>,
        "jinpu.wang@...ud.ionos.com" <jinpu.wang@...ud.ionos.com>,
        "damien.lemoal@...nsource.wdc.com" <damien.lemoal@...nsource.wdc.com>,
        "linux-scsi@...r.kernel.org" <linux-scsi@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "linuxarm@...wei.com" <linuxarm@...wei.com>,
        "yangxingui@...wei.com" <yangxingui@...wei.com>
Subject: Re: [PATCH v6 8/8] scsi: libsas: Update SATA dev FIS in
 sas_ata_task_done()

On Mon, Oct 17, 2022 at 05:20:35PM +0800, John Garry wrote:
> In sas_ata_task_done(), for commands which complete with error we set
> the SATA dev FIS status field with ATA_ERR. In ata_eh_analyze_tf() this
> would be interpreted as a HSM error. Set ATA_DRDY, which will lead libata
> to judge as a device error, which is a safer bet.
> 
> Signed-off-by: John Garry <john.garry@...wei.com>
> ---
>  drivers/scsi/libsas/sas_ata.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/scsi/libsas/sas_ata.c b/drivers/scsi/libsas/sas_ata.c
> index 61f64d54e67d..78e6046fb55a 100644
> --- a/drivers/scsi/libsas/sas_ata.c
> +++ b/drivers/scsi/libsas/sas_ata.c
> @@ -139,8 +139,8 @@ static void sas_ata_task_done(struct sas_task *task)
>  				qc->flags |= ATA_QCFLAG_FAILED;
>  			}
>  
> -			dev->sata_dev.fis[3] = 0x04; /* status err */
> -			dev->sata_dev.fis[2] = ATA_ERR;
> +			dev->sata_dev.fis[2] = ATA_ERR | ATA_DRDY; /* tf status */
> +			dev->sata_dev.fis[3] = ATA_ABORTED; /* tf error */
>  		}
>  	}
>  
> -- 
> 2.35.3
> 

Reviewed-by: Niklas Cassel <niklas.cassel@....com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ