• X
    scsi: hisi_sas: workaround STP link SoC bug · c7b9d369
    Xiaofei Tan 提交于
    After resetting the controller, the process of scanning SATA disks
    attached to an expander may fail occasionally. The issue is that the
    controller can't close the STP link created by target if the max link
    time is 0.
    
    To workaround this issue, we reject STP link after resetting the
    controller, and change the corresponding PHY to accept STP link only
    after receiving data.
    
    We do this check in cq interrupt handler. In order not to reduce
    efficiency, we use an variable to control whether we should check and
    change PHY to accept STP link.
    
    The function phys_reject_stp_links_v2_hw() should be called after
    resetting the controller.
    
    The solution of another SoC bug "SATA IO timeout", that also uses the
    same register to control STP link, is not effective before the PHY
    accepts STP link.
    Signed-off-by: NXiaofei Tan <tanxiaofei@huawei.com>
    Signed-off-by: NJohn Garry <john.garry@huawei.com>
    Reviewed-by: NJohannes Thumshirn <jthumshirn@suse.de>
    Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
    c7b9d369
hisi_sas.h 8.6 KB