unsigned int id = SCpnt->device->id;
struct BusLogic_TargetStatistics *stats = &HostAdapter->TargetStatistics[id];
+ int rc;
+
+ spin_lock_irq(SCpnt->device->host->host_lock);
+
BusLogic_IncrementErrorCounter(&stats->HostAdapterResetsRequested);
- return BusLogic_ResetHostAdapter(HostAdapter, false);
+ rc = BusLogic_ResetHostAdapter(HostAdapter, false);
+ spin_unlock_irq(SCpnt->device->host->host_lock);
+ return rc;
}
/*
int TargetID = Command->device->id;
struct BusLogic_CCB *CCB;
BusLogic_IncrementErrorCounter(&HostAdapter->TargetStatistics[TargetID].CommandAbortsRequested);
- /*
- If this Command has already completed, then no Abort is necessary.
- */
- if (Command->serial_number != Command->serial_number_at_timeout) {
- BusLogic_Warning("Unable to Abort Command to Target %d - " "Already Completed\n", HostAdapter, TargetID);
- return SUCCESS;
- }
/*
Attempt to find an Active CCB for this Command. If no Active CCB for this
Command is found, then no Abort is necessary.