diff options
Diffstat (limited to 'drivers/block/hd.c')
-rw-r--r-- | drivers/block/hd.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/block/hd.c b/drivers/block/hd.c index baaa9e486e50..5cb300b81c6a 100644 --- a/drivers/block/hd.c +++ b/drivers/block/hd.c | |||
@@ -410,7 +410,7 @@ static void bad_rw_intr(void) | |||
410 | if (req != NULL) { | 410 | if (req != NULL) { |
411 | struct hd_i_struct *disk = req->rq_disk->private_data; | 411 | struct hd_i_struct *disk = req->rq_disk->private_data; |
412 | if (++req->errors >= MAX_ERRORS || (hd_error & BBD_ERR)) { | 412 | if (++req->errors >= MAX_ERRORS || (hd_error & BBD_ERR)) { |
413 | end_request(req, 0); | 413 | __blk_end_request_cur(req, -EIO); |
414 | disk->special_op = disk->recalibrate = 1; | 414 | disk->special_op = disk->recalibrate = 1; |
415 | } else if (req->errors % RESET_FREQ == 0) | 415 | } else if (req->errors % RESET_FREQ == 0) |
416 | reset = 1; | 416 | reset = 1; |
@@ -466,7 +466,7 @@ ok_to_read: | |||
466 | req->buffer+512); | 466 | req->buffer+512); |
467 | #endif | 467 | #endif |
468 | if (req->current_nr_sectors <= 0) | 468 | if (req->current_nr_sectors <= 0) |
469 | end_request(req, 1); | 469 | __blk_end_request_cur(req, 0); |
470 | if (i > 0) { | 470 | if (i > 0) { |
471 | SET_HANDLER(&read_intr); | 471 | SET_HANDLER(&read_intr); |
472 | return; | 472 | return; |
@@ -505,7 +505,7 @@ ok_to_write: | |||
505 | --req->current_nr_sectors; | 505 | --req->current_nr_sectors; |
506 | req->buffer += 512; | 506 | req->buffer += 512; |
507 | if (!i || (req->bio && req->current_nr_sectors <= 0)) | 507 | if (!i || (req->bio && req->current_nr_sectors <= 0)) |
508 | end_request(req, 1); | 508 | __blk_end_request_cur(req, 0); |
509 | if (i > 0) { | 509 | if (i > 0) { |
510 | SET_HANDLER(&write_intr); | 510 | SET_HANDLER(&write_intr); |
511 | outsw(HD_DATA, req->buffer, 256); | 511 | outsw(HD_DATA, req->buffer, 256); |
@@ -548,7 +548,7 @@ static void hd_times_out(unsigned long dummy) | |||
548 | #ifdef DEBUG | 548 | #ifdef DEBUG |
549 | printk("%s: too many errors\n", name); | 549 | printk("%s: too many errors\n", name); |
550 | #endif | 550 | #endif |
551 | end_request(CURRENT, 0); | 551 | __blk_end_request_cur(CURRENT, -EIO); |
552 | } | 552 | } |
553 | hd_request(); | 553 | hd_request(); |
554 | spin_unlock_irq(hd_queue->queue_lock); | 554 | spin_unlock_irq(hd_queue->queue_lock); |
@@ -563,7 +563,7 @@ static int do_special_op(struct hd_i_struct *disk, struct request *req) | |||
563 | } | 563 | } |
564 | if (disk->head > 16) { | 564 | if (disk->head > 16) { |
565 | printk("%s: cannot handle device with more than 16 heads - giving up\n", req->rq_disk->disk_name); | 565 | printk("%s: cannot handle device with more than 16 heads - giving up\n", req->rq_disk->disk_name); |
566 | end_request(req, 0); | 566 | __blk_end_request_cur(req, -EIO); |
567 | } | 567 | } |
568 | disk->special_op = 0; | 568 | disk->special_op = 0; |
569 | return 1; | 569 | return 1; |
@@ -607,7 +607,7 @@ repeat: | |||
607 | ((block+nsect) > get_capacity(req->rq_disk))) { | 607 | ((block+nsect) > get_capacity(req->rq_disk))) { |
608 | printk("%s: bad access: block=%d, count=%d\n", | 608 | printk("%s: bad access: block=%d, count=%d\n", |
609 | req->rq_disk->disk_name, block, nsect); | 609 | req->rq_disk->disk_name, block, nsect); |
610 | end_request(req, 0); | 610 | __blk_end_request_cur(req, -EIO); |
611 | goto repeat; | 611 | goto repeat; |
612 | } | 612 | } |
613 | 613 | ||
@@ -647,7 +647,7 @@ repeat: | |||
647 | break; | 647 | break; |
648 | default: | 648 | default: |
649 | printk("unknown hd-command\n"); | 649 | printk("unknown hd-command\n"); |
650 | end_request(req, 0); | 650 | __blk_end_request_cur(req, -EIO); |
651 | break; | 651 | break; |
652 | } | 652 | } |
653 | } | 653 | } |