aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/sbus/char/jsflash.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/sbus/char/jsflash.c')
-rw-r--r--drivers/sbus/char/jsflash.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/sbus/char/jsflash.c b/drivers/sbus/char/jsflash.c
index 09617884a50b..2132c906e53a 100644
--- a/drivers/sbus/char/jsflash.c
+++ b/drivers/sbus/char/jsflash.c
@@ -188,8 +188,8 @@ static void jsfd_do_request(struct request_queue *q)
188 188
189 while ((req = elv_next_request(q)) != NULL) { 189 while ((req = elv_next_request(q)) != NULL) {
190 struct jsfd_part *jdp = req->rq_disk->private_data; 190 struct jsfd_part *jdp = req->rq_disk->private_data;
191 unsigned long offset = req->sector << 9; 191 unsigned long offset = blk_rq_pos(req) << 9;
192 size_t len = req->current_nr_sectors << 9; 192 size_t len = blk_rq_cur_sectors(req) << 9;
193 193
194 if ((offset + len) > jdp->dsize) { 194 if ((offset + len) > jdp->dsize) {
195 __blk_end_request_cur(req, -EIO); 195 __blk_end_request_cur(req, -EIO);