Move source tree closer to the 2.6.32.17 mainline
/drivers/ata/libata-eh.c
blob:7d8d3c3b4c80b09dbf5f9d7742094cffd2f212c6 -> blob:e30b9e74794b2966571b0fb660544bd329304c65
--- drivers/ata/libata-eh.c
+++ drivers/ata/libata-eh.c
@@ -870,6 +870,8 @@ static void ata_eh_set_pending(struct at
void ata_qc_schedule_eh(struct ata_queued_cmd *qc)
{
struct ata_port *ap = qc->ap;
+ struct request_queue *q = qc->scsicmd->device->request_queue;
+ unsigned long flags;
WARN_ON(!ap->ops->error_handler);
@@ -881,7 +883,9 @@ void ata_qc_schedule_eh(struct ata_queue
* Note that ATA_QCFLAG_FAILED is unconditionally set after
* this function completes.
*/
+ spin_lock_irqsave(q->queue_lock, flags);
blk_abort_request(qc->scsicmd->request);
+ spin_unlock_irqrestore(q->queue_lock, flags);
}
/**
@@ -1615,6 +1619,7 @@ void ata_eh_analyze_ncq_error(struct ata
}
/* okay, this error is ours */
+ memset(&tf, 0, sizeof(tf));
rc = ata_eh_read_log_10h(dev, &tag, &tf);
if (rc) {
ata_link_printk(link, KERN_ERR, "failed to read log page 10h "