From: Omar Sandoval <osandov@xxxxxx> When swim3_end_request() gets passed an error, it seems that the intent is to end the whole request, but we're only ending the current segment. Signed-off-by: Omar Sandoval <osandov@xxxxxx> --- drivers/block/swim3.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/block/swim3.c b/drivers/block/swim3.c index df7ebe016e2c..24e121ee274b 100644 --- a/drivers/block/swim3.c +++ b/drivers/block/swim3.c @@ -266,7 +266,7 @@ static bool swim3_end_request(struct floppy_state *fs, blk_status_t err, unsigne err, nr_bytes, req); if (err) - nr_bytes = blk_rq_cur_bytes(req); + nr_bytes = blk_rq_bytes(req); rc = __blk_end_request(req, err, nr_bytes); if (rc) return true; -- 2.19.1