scsi: hisi_sas: fix the issue of setting linkrate register
authorXiaofei Tan <tanxiaofei@huawei.com>
Wed, 7 Mar 2018 12:25:08 +0000 (20:25 +0800)
committerMartin K. Petersen <martin.petersen@oracle.com>
Tue, 13 Mar 2018 01:55:24 +0000 (21:55 -0400)
commit0006ce29e87ba357f64ee73e92c8aefc270fd315
treea377470b9ede467d27170b39b7f868d774873e7b
parenteba8c20c7178af9673ad842b0f68251c891c8546
scsi: hisi_sas: fix the issue of setting linkrate register

It is not right to set the register PROG_PHY_LINK_RATE while PHY is still
enabled. So if we want to change PHY linkrate, we need to disable PHY before
setting the register PROG_PHY_LINK_RATE, and then start-up PHY. This patch
is to fix this issue.

Signed-off-by: Xiaofei Tan <tanxiaofei@huawei.com>
Signed-off-by: John Garry <john.garry@huawei.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/hisi_sas/hisi_sas_v1_hw.c
drivers/scsi/hisi_sas/hisi_sas_v2_hw.c
drivers/scsi/hisi_sas/hisi_sas_v3_hw.c