Commit 75249268 authored by John Garry's avatar John Garry Committed by Martin K. Petersen

hisi_sas: use device linkrate in MCR for v2 hw

Contrary to the field name, the MCR (max connection rate) in the ITCT
should hold the device linkrate (linkrate of the connected phy), and not
the max linkrate.

This fixes an issue seen where some SATA drives connected through an
expander which would not attach.
Signed-off-by: default avatarJohn Garry <john.garry@huawei.com>
Reviewed-by: default avatarZhangfei Gao <zhangfei.gao@linaro.org>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 9b1d6c89
...@@ -544,7 +544,7 @@ static void setup_itct_v2_hw(struct hisi_hba *hisi_hba, ...@@ -544,7 +544,7 @@ static void setup_itct_v2_hw(struct hisi_hba *hisi_hba,
} }
qw0 |= ((1 << ITCT_HDR_VALID_OFF) | qw0 |= ((1 << ITCT_HDR_VALID_OFF) |
(device->max_linkrate << ITCT_HDR_MCR_OFF) | (device->linkrate << ITCT_HDR_MCR_OFF) |
(1 << ITCT_HDR_VLN_OFF) | (1 << ITCT_HDR_VLN_OFF) |
(port->id << ITCT_HDR_PORT_ID_OFF)); (port->id << ITCT_HDR_PORT_ID_OFF));
itct->qw0 = cpu_to_le64(qw0); itct->qw0 = cpu_to_le64(qw0);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment