]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
isci: Requests that do not start must be set to "complete"
authorJeff Skirvin <jeffrey.d.skirvin@intel.com>
Mon, 20 Jun 2011 21:09:11 +0000 (14:09 -0700)
committerDan Williams <dan.j.williams@intel.com>
Sun, 3 Jul 2011 11:04:50 +0000 (04:04 -0700)
Requests that fail at start because of a reset pending condition
must be set to complete in order to allow for later cleanup.

Signed-off-by: Jeff Skirvin <jeffrey.d.skirvin@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
drivers/scsi/isci/request.c

index 3a891d32c3315228997408c5c72d9ebed64cab11..5879e5f308e609b6ede561daf8849fd621796eab 100644 (file)
@@ -3678,18 +3678,19 @@ int isci_request_execute(
         * Update it's status and add it to the list in the
         * remote device object.
         */
-       isci_request_change_state(request, started);
        list_add(&request->dev_node, &isci_device->reqs_in_process);
 
        if (status == SCI_SUCCESS) {
                /* Save the tag for possible task mgmt later. */
                request->io_tag = request->sci.io_tag;
+               isci_request_change_state(request, started);
        } else {
                /* The request did not really start in the
                 * hardware, so clear the request handle
                 * here so no terminations will be done.
                 */
                request->terminated = true;
+               isci_request_change_state(request, completed);
        }
        spin_unlock_irqrestore(&isci_host->scic_lock, flags);