diff options
Diffstat (limited to 'drivers/ide/ide-atapi.c')
-rw-r--r-- | drivers/ide/ide-atapi.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/ide/ide-atapi.c b/drivers/ide/ide-atapi.c index afe5a4323879..e4a02a05fc81 100644 --- a/drivers/ide/ide-atapi.c +++ b/drivers/ide/ide-atapi.c | |||
@@ -367,7 +367,6 @@ static ide_startstop_t ide_pc_intr(ide_drive_t *drive) | |||
367 | /* No more interrupts */ | 367 | /* No more interrupts */ |
368 | if ((stat & ATA_DRQ) == 0) { | 368 | if ((stat & ATA_DRQ) == 0) { |
369 | int uptodate, error; | 369 | int uptodate, error; |
370 | unsigned int done; | ||
371 | 370 | ||
372 | debug_log("Packet command completed, %d bytes transferred\n", | 371 | debug_log("Packet command completed, %d bytes transferred\n", |
373 | pc->xferred); | 372 | pc->xferred); |
@@ -406,12 +405,6 @@ static ide_startstop_t ide_pc_intr(ide_drive_t *drive) | |||
406 | if ((pc->flags & PC_FLAG_WAIT_FOR_DSC) && (stat & ATA_DSC) == 0) | 405 | if ((pc->flags & PC_FLAG_WAIT_FOR_DSC) && (stat & ATA_DSC) == 0) |
407 | dsc = 1; | 406 | dsc = 1; |
408 | 407 | ||
409 | /* | ||
410 | * ->pc_callback() might change rq->data_len for | ||
411 | * residual count, cache total length. | ||
412 | */ | ||
413 | done = blk_rq_bytes(rq); | ||
414 | |||
415 | /* Command finished - Call the callback function */ | 408 | /* Command finished - Call the callback function */ |
416 | uptodate = drive->pc_callback(drive, dsc); | 409 | uptodate = drive->pc_callback(drive, dsc); |
417 | 410 | ||
@@ -431,7 +424,7 @@ static ide_startstop_t ide_pc_intr(ide_drive_t *drive) | |||
431 | error = uptodate ? 0 : -EIO; | 424 | error = uptodate ? 0 : -EIO; |
432 | } | 425 | } |
433 | 426 | ||
434 | ide_complete_rq(drive, error, done); | 427 | ide_complete_rq(drive, error, blk_rq_bytes(rq)); |
435 | return ide_stopped; | 428 | return ide_stopped; |
436 | } | 429 | } |
437 | 430 | ||