diff options
Diffstat (limited to 'drivers/block/z2ram.c')
-rw-r--r-- | drivers/block/z2ram.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/drivers/block/z2ram.c b/drivers/block/z2ram.c index c909c1a3f650..4575171e5beb 100644 --- a/drivers/block/z2ram.c +++ b/drivers/block/z2ram.c | |||
@@ -71,10 +71,7 @@ static void do_z2_request(struct request_queue *q) | |||
71 | { | 71 | { |
72 | struct request *req; | 72 | struct request *req; |
73 | 73 | ||
74 | req = elv_next_request(q); | 74 | req = blk_fetch_request(q); |
75 | if (req) | ||
76 | blkdev_dequeue_request(req); | ||
77 | |||
78 | while (req) { | 75 | while (req) { |
79 | unsigned long start = blk_rq_pos(req) << 9; | 76 | unsigned long start = blk_rq_pos(req) << 9; |
80 | unsigned long len = blk_rq_cur_bytes(req); | 77 | unsigned long len = blk_rq_cur_bytes(req); |
@@ -100,11 +97,8 @@ static void do_z2_request(struct request_queue *q) | |||
100 | len -= size; | 97 | len -= size; |
101 | } | 98 | } |
102 | done: | 99 | done: |
103 | if (!__blk_end_request_cur(req, err)) { | 100 | if (!__blk_end_request_cur(req, err)) |
104 | req = elv_next_request(q); | 101 | req = blk_fetch_request(q); |
105 | if (req) | ||
106 | blkdev_dequeue_request(req); | ||
107 | } | ||
108 | } | 102 | } |
109 | } | 103 | } |
110 | 104 | ||