提交 5d35fec3 编写于 作者: L luojiaxing 提交者: Xie XiuQi

scsi: hisi_sas: Feed back linkrate(max/min) value after modified each time at...

scsi: hisi_sas: Feed back linkrate(max/min) value after modified each time at directly attached situation

At directly attached situation,user modify the sysfs interface of
maximum_linkrate and minimum_linkrate to renegotiate the linkrate
between sas controller and sas/sata disk. The value of both files
mentioned above should have change to user setting after renegotiate
is over,but it remain unchanged.

To fix this bug, maximum_linkrate and minimum_linkrate will be
directly feed back to upper layer by synchronize those value
to hisi_hab->phy[phy_no]->sas_phy->phy when receive the
request of renegotiate

This bug is introduced by the patch
<757db2da>"scsi:hisi_sas:introduce hisi_sas_phy_set_linkrate()" and
now have been fixed.
Signed-off-by: Nluojiaxing <luojiaxing@huawei.com>
Signed-off-by: Njohn Garry <john.garry@huawei.com>
上级 1cc9991a
...@@ -933,6 +933,10 @@ static void hisi_sas_phy_set_linkrate(struct hisi_hba *hisi_hba, int phy_no, ...@@ -933,6 +933,10 @@ static void hisi_sas_phy_set_linkrate(struct hisi_hba *hisi_hba, int phy_no,
_r.maximum_linkrate = max; _r.maximum_linkrate = max;
_r.minimum_linkrate = min; _r.minimum_linkrate = min;
/* Feed back modified linkrate value pass from upper layer */
sas_phy->phy->maximum_linkrate = max;
sas_phy->phy->minimum_linkrate = min;
hisi_hba->hw->phy_disable(hisi_hba, phy_no); hisi_hba->hw->phy_disable(hisi_hba, phy_no);
msleep(100); msleep(100);
hisi_hba->hw->phy_set_linkrate(hisi_hba, phy_no, &_r); hisi_hba->hw->phy_set_linkrate(hisi_hba, phy_no, &_r);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册