[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1240891577-4813-11-git-send-email-tj@kernel.org>
Date: Tue, 28 Apr 2009 13:06:13 +0900
From: Tejun Heo <tj@...nel.org>
To: axboe@...nel.dk, linux-kernel@...r.kernel.org, donari75@...il.com,
bzolnier@...il.com, joerg@...chain.net, geert@...ux-m68k.org,
davem@...emloft.net, jdike@...ux.intel.com,
benh@...nel.crashing.org, Laurent@...vier.info
Cc: Tejun Heo <tj@...nel.org>
Subject: [PATCH 10/14] swim: clean up request completion paths
swim curiously tries to update request parameters before calling
__blk_end_request() when __blk_end_request() will do it anyway and
unnecessarily checks whether current_nr_sectors is zero right after
fetching.
Drop unnecessary stuff and use standard block layer mechanisms.
[ Impact: cleanup ]
Signed-off-by: Tejun Heo <tj@...nel.org>
Cc: Laurent Vivier <Laurent@...vier.info>
---
drivers/block/swim.c | 7 -------
1 files changed, 0 insertions(+), 7 deletions(-)
diff --git a/drivers/block/swim.c b/drivers/block/swim.c
index 6544a7b..97ef426 100644
--- a/drivers/block/swim.c
+++ b/drivers/block/swim.c
@@ -535,10 +535,6 @@ static void redo_fd_request(struct request_queue *q)
__blk_end_request_cur(req, -EIO);
continue;
}
- if (req->current_nr_sectors == 0) {
- __blk_end_request_cur(req, 0);
- continue;
- }
if (!fs->disk_in) {
__blk_end_request_cur(req, -EIO);
continue;
@@ -561,9 +557,6 @@ static void redo_fd_request(struct request_queue *q)
__blk_end_request_cur(req, -EIO);
continue;
}
- req->nr_sectors -= req->current_nr_sectors;
- req->sector += req->current_nr_sectors;
- req->buffer += req->current_nr_sectors * 512;
__blk_end_request_cur(req, 0);
break;
}
--
1.6.0.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists