aboutsummaryrefslogtreecommitdiffstats
path: root/block/blk-exec.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@infradead.org>2013-10-04 09:49:11 -0400
committerJens Axboe <axboe@kernel.dk>2013-10-25 06:55:59 -0400
commit71fe07d040626de7b72244bf6de889c2e0f5aea3 (patch)
tree6c4d6bed7e8510fb2c9a105dba62d2342e6fc897 /block/blk-exec.c
parent5953316dbf90067ebdeca626c34488bc166b73a8 (diff)
block: remove request ref_count
This reference count has been around since before git history, but the only place where it's used is in blk_execute_rq, and ther it is entirely useless as it is incremented before submitting the request and decremented in the end_io handler before waking up the submitter thread. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/blk-exec.c')
-rw-r--r--block/blk-exec.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/block/blk-exec.c b/block/blk-exec.c
index ae4f27d7944e..6b18d82d91c5 100644
--- a/block/blk-exec.c
+++ b/block/blk-exec.c
@@ -24,7 +24,6 @@ static void blk_end_sync_rq(struct request *rq, int error)
24 struct completion *waiting = rq->end_io_data; 24 struct completion *waiting = rq->end_io_data;
25 25
26 rq->end_io_data = NULL; 26 rq->end_io_data = NULL;
27 __blk_put_request(rq->q, rq);
28 27
29 /* 28 /*
30 * complete last, if this is a stack request the process (and thus 29 * complete last, if this is a stack request the process (and thus
@@ -103,12 +102,6 @@ int blk_execute_rq(struct request_queue *q, struct gendisk *bd_disk,
103 int err = 0; 102 int err = 0;
104 unsigned long hang_check; 103 unsigned long hang_check;
105 104
106 /*
107 * we need an extra reference to the request, so we can look at
108 * it after io completion
109 */
110 rq->ref_count++;
111
112 if (!rq->sense) { 105 if (!rq->sense) {
113 memset(sense, 0, sizeof(sense)); 106 memset(sense, 0, sizeof(sense));
114 rq->sense = sense; 107 rq->sense = sense;