diff options
Diffstat (limited to 'drivers/scsi/ide-scsi.c')
-rw-r--r-- | drivers/scsi/ide-scsi.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/scsi/ide-scsi.c b/drivers/scsi/ide-scsi.c index e67cf8aa9462..ed92cf7a7682 100644 --- a/drivers/scsi/ide-scsi.c +++ b/drivers/scsi/ide-scsi.c | |||
@@ -388,11 +388,13 @@ static ide_startstop_t idescsi_pc_intr (ide_drive_t *drive) | |||
388 | return ide_stopped; | 388 | return ide_stopped; |
389 | } | 389 | } |
390 | if (pc->flags & PC_FLAG_DMA_IN_PROGRESS) { | 390 | if (pc->flags & PC_FLAG_DMA_IN_PROGRESS) { |
391 | if (hwif->dma_ops->dma_end(drive)) | ||
392 | pc->flags |= PC_FLAG_DMA_ERROR; | ||
393 | else | ||
394 | pc->xferred = pc->req_xfer; | ||
391 | #if IDESCSI_DEBUG_LOG | 395 | #if IDESCSI_DEBUG_LOG |
392 | printk ("ide-scsi: %s: DMA complete\n", drive->name); | 396 | printk ("ide-scsi: %s: DMA complete\n", drive->name); |
393 | #endif /* IDESCSI_DEBUG_LOG */ | 397 | #endif /* IDESCSI_DEBUG_LOG */ |
394 | pc->xferred = pc->req_xfer; | ||
395 | (void)hwif->dma_ops->dma_end(drive); | ||
396 | } | 398 | } |
397 | 399 | ||
398 | /* Clear the interrupt */ | 400 | /* Clear the interrupt */ |
@@ -405,7 +407,7 @@ static ide_startstop_t idescsi_pc_intr (ide_drive_t *drive) | |||
405 | " transferred\n", pc->xferred); | 407 | " transferred\n", pc->xferred); |
406 | pc->flags &= ~PC_FLAG_DMA_IN_PROGRESS; | 408 | pc->flags &= ~PC_FLAG_DMA_IN_PROGRESS; |
407 | local_irq_enable_in_hardirq(); | 409 | local_irq_enable_in_hardirq(); |
408 | if (stat & ERR_STAT) | 410 | if ((stat & ERR_STAT) || (pc->flags & PC_FLAG_DMA_ERROR)) |
409 | rq->errors++; | 411 | rq->errors++; |
410 | idescsi_end_request (drive, 1, 0); | 412 | idescsi_end_request (drive, 1, 0); |
411 | return ide_stopped; | 413 | return ide_stopped; |