aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/hisi_sas/hisi_sas.h
diff options
context:
space:
mode:
authorXiaofei Tan <tanxiaofei@huawei.com>2017-10-24 23:51:47 +0800
committerMartin K. Petersen <martin.petersen@oracle.com>2017-10-31 12:28:01 -0400
commit571295f8055c0b69c9911021ae6cf1a6973cf517 (patch)
tree21832e1afa9fd005bd89b063f4e39a982f5d1c8a /drivers/scsi/hisi_sas/hisi_sas.h
parentscsi: hisi_sas: fix a bug when free device for v3 hw (diff)
downloadlinux-dev-571295f8055c0b69c9911021ae6cf1a6973cf517.tar.xz
linux-dev-571295f8055c0b69c9911021ae6cf1a6973cf517.zip
scsi: hisi_sas: complete all tasklets prior to host reset
The CQ event is handled in tasklet context, and it could be delayed if the system loading is high. It is possible to run into some problems when executing a host reset when cq_tasklet_vx_hw() is being executed. So, prior to host reset, execute tasklet_kill() to ensure that all CQ tasklets are complete. Besides, as the function hisi_sas_wait_tasklets_done() is added to do tasklet_kill(), this patch refactors some code where tasklet_kill() is used. 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>
Diffstat (limited to 'drivers/scsi/hisi_sas/hisi_sas.h')
-rw-r--r--drivers/scsi/hisi_sas/hisi_sas.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/scsi/hisi_sas/hisi_sas.h b/drivers/scsi/hisi_sas/hisi_sas.h
index c65d151411e0..c5fd545030e2 100644
--- a/drivers/scsi/hisi_sas/hisi_sas.h
+++ b/drivers/scsi/hisi_sas/hisi_sas.h
@@ -426,4 +426,5 @@ extern void hisi_sas_slot_task_free(struct hisi_hba *hisi_hba,
struct hisi_sas_slot *slot);
extern void hisi_sas_init_mem(struct hisi_hba *hisi_hba);
extern void hisi_sas_rst_work_handler(struct work_struct *work);
+extern void hisi_sas_kill_tasklets(struct hisi_hba *hisi_hba);
#endif