From 7df272f95cdbe959e0513f626db1a1dbe3f11078 Mon Sep 17 00:00:00 2001 From: Jeff Skirvin Date: Thu, 8 Mar 2012 22:42:00 -0800 Subject: [PATCH] --- yaml --- r: 302568 b: refs/heads/master c: 08c031e4e3294a66a64074e12482abda846dd39c h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/scsi/isci/task.c | 14 ++++++++------ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/[refs] b/[refs] index 750dca1cb693..0518ca9d3b68 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 9608b6408e637abeec101abb6aebd3343f0ebac4 +refs/heads/master: 08c031e4e3294a66a64074e12482abda846dd39c diff --git a/trunk/drivers/scsi/isci/task.c b/trunk/drivers/scsi/isci/task.c index 222fb0de4d59..5d738fd5f882 100644 --- a/trunk/drivers/scsi/isci/task.c +++ b/trunk/drivers/scsi/isci/task.c @@ -439,16 +439,18 @@ int isci_task_lu_reset(struct domain_device *dev, u8 *lun) goto out; } + /* Suspend the RNC, kill all TCs */ + if (isci_remote_device_suspend_terminate(ihost, idev, NULL) + != SCI_SUCCESS) { + /* The suspend/terminate only fails if isci_get_device fails */ + ret = TMF_RESP_FUNC_FAILED; + goto out; + } + /* All pending I/Os have been terminated and cleaned up. */ if (dev_is_sata(dev)) { sas_ata_schedule_reset(dev); ret = TMF_RESP_FUNC_COMPLETE; } else { - /* Suspend the RNC, kill all TCs */ - if (isci_remote_device_suspend_terminate(ihost, idev, NULL) - != SCI_SUCCESS) { - ret = TMF_RESP_FUNC_FAILED; - goto out; - } /* Send the task management part of the reset. */ ret = isci_task_send_lu_reset_sas(ihost, idev, lun); }