diff options
author | John Garry <john.garry@huawei.com> | 2017-03-22 18:25:35 +0100 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2017-03-23 16:12:02 +0100 |
commit | 8b05ad6a9dbc4306c8eaf0f5269206647ed1ad7e (patch) | |
tree | e19281e19c87928f06cbc262709c407a4b6079e8 /drivers/scsi/hisi_sas | |
parent | scsi: hisi_sas: rename hisi_sas_link_timeout_{enable, disable}_link (diff) | |
download | linux-8b05ad6a9dbc4306c8eaf0f5269206647ed1ad7e.tar.xz linux-8b05ad6a9dbc4306c8eaf0f5269206647ed1ad7e.zip |
scsi: hisi_sas: add hisi_sas_clear_nexus_ha()
Add function for upper-layer to reset controller when all else fails.
Signed-off-by: John Garry <john.garry@huawei.com>
Signed-off-by: Xiang Chen <chenxiang66@hisilicon.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/hisi_sas')
-rw-r--r-- | drivers/scsi/hisi_sas/hisi_sas_main.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/scsi/hisi_sas/hisi_sas_main.c b/drivers/scsi/hisi_sas/hisi_sas_main.c index 3d63a24fea54..f86263b3bf1c 100644 --- a/drivers/scsi/hisi_sas/hisi_sas_main.c +++ b/drivers/scsi/hisi_sas/hisi_sas_main.c @@ -1070,6 +1070,13 @@ out: return rc; } +static int hisi_sas_clear_nexus_ha(struct sas_ha_struct *sas_ha) +{ + struct hisi_hba *hisi_hba = sas_ha->lldd_ha; + + return hisi_sas_controller_reset(hisi_hba); +} + static int hisi_sas_query_task(struct sas_task *task) { struct scsi_lun lun; @@ -1368,6 +1375,7 @@ static struct sas_domain_function_template hisi_sas_transport_ops = { .lldd_I_T_nexus_reset = hisi_sas_I_T_nexus_reset, .lldd_lu_reset = hisi_sas_lu_reset, .lldd_query_task = hisi_sas_query_task, + .lldd_clear_nexus_ha = hisi_sas_clear_nexus_ha, .lldd_port_formed = hisi_sas_port_formed, }; |