Patch "scsi: hisi_sas: Set a port invalid only if there are no devices attached when refreshing port id" has been added to the 5.15-stable tree

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

 



This is a note to let you know that I've just added the patch titled

    scsi: hisi_sas: Set a port invalid only if there are no devices attached when refreshing port id

to the 5.15-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     scsi-hisi_sas-set-a-port-invalid-only-if-there-are-n.patch
and it can be found in the queue-5.15 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 5a5f8cb5f48b6da9cd765c8cd2500f2b60a91e9e
Author: Yihang Li <liyihang9@xxxxxxxxxx>
Date:   Wed Jan 4 12:03:20 2023 +0800

    scsi: hisi_sas: Set a port invalid only if there are no devices attached when refreshing port id
    
    [ Upstream commit f58c89700630da6554b24fd3df293a24874c10c1 ]
    
    Currently the driver sets the port invalid if one phy in the port is not
    enabled, which may cause issues in expander situation. In directly attached
    situation, if phy up doesn't occur in time when refreshing port id, the
    port is incorrectly set to invalid which will also cause disk lost.
    
    Therefore set a port invalid only if there are no devices attached to the
    port.
    
    Signed-off-by: Yihang Li <liyihang9@xxxxxxxxxx>
    Signed-off-by: Xiang Chen <chenxiang66@xxxxxxxxxxxxx>
    Link: https://lore.kernel.org/r/1672805000-141102-3-git-send-email-chenxiang66@xxxxxxxxxxxxx
    Signed-off-by: Martin K. Petersen <martin.petersen@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/scsi/hisi_sas/hisi_sas_main.c b/drivers/scsi/hisi_sas/hisi_sas_main.c
index 9515c45affa5..7d93783c09a5 100644
--- a/drivers/scsi/hisi_sas/hisi_sas_main.c
+++ b/drivers/scsi/hisi_sas/hisi_sas_main.c
@@ -1414,7 +1414,7 @@ static void hisi_sas_refresh_port_id(struct hisi_hba *hisi_hba)
 				device->linkrate = phy->sas_phy.linkrate;
 
 			hisi_hba->hw->setup_itct(hisi_hba, sas_dev);
-		} else
+		} else if (!port->port_attached)
 			port->id = 0xff;
 	}
 }



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux