Skip to content
Snippets Groups Projects
  1. Sep 28, 2022
    • Xingui Yang's avatar
      scsi: hisi_sas: Modify v3 HW ATA completion process when SATA disk is in error status · 63c0c05a
      Xingui Yang authored
      driver inclusion
      category: bugfix
      bugzilla: https://gitee.com/openeuler/kernel/issues/I5Q63H
      CVE: NA
      
      -------------------------------------
      
      When an NCQ error occurs, SAS controller will abnormally complete the I/Os
      that newly delivered to disk, and bit8 in CQ dw3 will be set to 1 to
      indicate current SATA disk is in error status. The current processing flow
      is set ts->stat to SAS_OPEN_REJECT and then sas_ata_task_done() will set
      fis stat to ATA_ERR. After analyzed by ata_eh_analyze_tf(), err_mask will
      set to AC_ERR_HSM. If media error occurs for four times within 10 minutes
      and the chip rejects new I/Os for four times, NCQ will be disabled due to
      excessive errors.
      
      However, if media error occurs multiple times, the NCQ mode shouldn't be
      disabled. Therefore, use sas_task_abort() to handle abnormally completed
      I/Os when SATA disk is in error status.
      
      [10253.397429] hisi_sas_v3_hw 0000:b4:02.0: erroneous completion disk err...
      63c0c05a
  2. Aug 25, 2022
  3. Jul 07, 2022
  4. May 13, 2022
  5. Dec 20, 2021
  6. Nov 04, 2021
  7. Nov 01, 2021
  8. Oct 30, 2021
  9. Sep 30, 2021
  10. Sep 23, 2021
    • yangxingui's avatar
      scsi: hisi_sas: set sense data when the sas disk's I/O abnormally completed · c0762a73
      yangxingui authored
      
      driver inclusion
      category: bugfix
      bugzilla: NA
      CVE: NA
      
      ---------------------------
      The sense data of the sas disk is used by the kernel and upper layers to
      perform some policies on disks when the I/O is abnormally completed.
      
      Such as the logs as follow, if the driver transmit sense data to the upper
      layer, the disk may be repaired by remap policy of disk management system.
      
      [Wed Sep 15 13:03:04 2021] hisi_sas_v3_hw 0000:74:02.0: erroneous
      completion iptt=3342 task=        pK-error dev id=0
      sas_addr=0x5541310520e0b000 CQ hdr: 0x1503 0xd0e 0x0 0x20000
      Error info: 0x1200 0x0 0x0 0x40
      [Wed Sep 15 13:03:04 2021] hisi_sas_v3_hw 0000:74:02.0: data underflow,
      rsp_code:0x72, sensekey:0x3, ASC:0x11, ASCQ:0x0.
      
      Signed-off-by: default avataryangxingui <yangxingui@huawei.com>
      Reviewed-by: default avatarouyangdelong &lt; <ouyangdelong@huawei.com>
      Signed-off-by: default avatarYang Yingliang <yangyingliang@huawei.com>
      c0762a73
  11. Sep 15, 2021
  12. Aug 20, 2021
  13. Jun 11, 2021
    • Yufen Yu's avatar
      scsi: libsas: add lun number check in .slave_alloc callback · efa2c015
      Yufen Yu authored
      hulk inclusion
      category: bugfix
      bugzilla: 51878
      CVE: NA
      
      -------------------------------------------------
      
      We found that offline a sata device on hisi sas control and then
      scanning the host can probe 255 non-existent devices into system.
      
      [root@localhost ~]# lsscsi
        [2:0:0:0]    disk    ATA      Samsung SSD 860  2B6Q  /dev/sda
        [2:0:1:0]    disk    ATA      WDC WD2003FYYS-3 1D01  /dev/sdb
        [2:0:2:0]    disk    SEAGATE  ST600MM0006      B001  /dev/sdc
      
       1) echo "offline" > /sys/block/sdb/device/state
       2) echo "- - -" > /sys/class/scsi_host/host2/scan
      
      Then, we can see another 255 non-existent devices in system:
        [root@localhost ~]# lsscsi
        [2:0:0:0]    disk    ATA      Samsung SSD 860  2B6Q  /dev/sda
        [2:0:1:0]    disk    ATA      WDC WD2003FYYS-3 1D01  /dev/sdb
        [2:0:1:1]    disk    ATA      WDC WD2003FYYS-3 1D01  /dev/sdh
        ...
        [2:0:1:255]  disk    ATA      WDC WD2003FYYS-3 1D01  /dev/sdjb
      
      After REPORT LUN command issued to the offlin...
      efa2c015
  14. Jan 11, 2021
  15. Apr 22, 2020
  16. Jan 12, 2020
  17. Dec 27, 2019