diff options
Diffstat (limited to 'drivers/ide')
-rw-r--r-- | drivers/ide/ide-dma.c | 20 |
1 files changed, 4 insertions, 16 deletions
diff --git a/drivers/ide/ide-dma.c b/drivers/ide/ide-dma.c index a0b8cab1d9a6..d9123ecae4a9 100644 --- a/drivers/ide/ide-dma.c +++ b/drivers/ide/ide-dma.c | |||
@@ -510,23 +510,11 @@ ide_startstop_t ide_dma_timeout_retry(ide_drive_t *drive, int error) | |||
510 | /* | 510 | /* |
511 | * un-busy drive etc and make sure request is sane | 511 | * un-busy drive etc and make sure request is sane |
512 | */ | 512 | */ |
513 | |||
514 | rq = hwif->rq; | 513 | rq = hwif->rq; |
515 | if (!rq) | 514 | if (rq) { |
516 | goto out; | 515 | hwif->rq = NULL; |
517 | 516 | rq->errors = 0; | |
518 | hwif->rq = NULL; | 517 | } |
519 | |||
520 | rq->errors = 0; | ||
521 | |||
522 | if (!rq->bio) | ||
523 | goto out; | ||
524 | |||
525 | rq->sector = rq->bio->bi_sector; | ||
526 | rq->current_nr_sectors = bio_iovec(rq->bio)->bv_len >> 9; | ||
527 | rq->hard_cur_sectors = rq->current_nr_sectors; | ||
528 | rq->buffer = bio_data(rq->bio); | ||
529 | out: | ||
530 | return ret; | 518 | return ret; |
531 | } | 519 | } |
532 | 520 | ||