hisi_sas: change tmf func complete check
authorJohn Garry <john.garry@huawei.com>
Thu, 25 Feb 2016 09:42:10 +0000 (17:42 +0800)
committerMartin K. Petersen <martin.petersen@oracle.com>
Tue, 1 Mar 2016 02:00:03 +0000 (21:00 -0500)
In hisi_sas_exec_internal_tmf_task(), the check for
SAM_STAT_GOOD is replaced with
TMF_RESP_FUNC_COMPLETE, which is a genuine tmf
response code.
SAM_STAT_GOOD and TMF_RESP_FUNC_COMPLETE have the
same value, so this is why it worked before.

Signed-off-by: John Garry <john.garry@huawei.com>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/hisi_sas/hisi_sas_main.c

index 2194917bd84de14ddc446766ba69490362a7d099..58ca336c9509c97e48fdee88542b3119a94355c3 100644 (file)
@@ -661,7 +661,7 @@ static int hisi_sas_exec_internal_tmf_task(struct domain_device *device,
                }
 
                if (task->task_status.resp == SAS_TASK_COMPLETE &&
-                   task->task_status.stat == SAM_STAT_GOOD) {
+                    task->task_status.stat == TMF_RESP_FUNC_COMPLETE) {
                        res = TMF_RESP_FUNC_COMPLETE;
                        break;
                }