提交 9f16505c 编写于 作者: J Jason Yan 提交者: Xie XiuQi

scsi: libsas: re-init the negotiated_linkrate when phy down v2

When the PHY is down or disabled, the old negotiated_linkrate still can
be seen by sysfs. Re-init the negotiated_linkrate so that it is
consistent with the state of the PHY.
Signed-off-by: NJason Yan <yanaijie@huawei.com>
上级 0ddaad05
...@@ -449,6 +449,9 @@ static inline void sas_phy_disconnected(struct asd_sas_phy *phy) ...@@ -449,6 +449,9 @@ static inline void sas_phy_disconnected(struct asd_sas_phy *phy)
{ {
phy->oob_mode = OOB_NOT_CONNECTED; phy->oob_mode = OOB_NOT_CONNECTED;
phy->linkrate = SAS_LINK_RATE_UNKNOWN; phy->linkrate = SAS_LINK_RATE_UNKNOWN;
if (phy->phy)
phy->phy->negotiated_linkrate = SAS_LINK_RATE_UNKNOWN;
} }
static inline unsigned int to_sas_gpio_od(int device, int bit) static inline unsigned int to_sas_gpio_od(int device, int bit)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册