Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 84e9e03c authored by Jens Axboe's avatar Jens Axboe
Browse files

block: make blk_rq_map_user() clear ->bio if it unmaps it



That way the interface is symmetric, and calling blk_rq_unmap_user()
on the request wont oops.

Signed-off-by: default avatarJens Axboe <jens.axboe@oracle.com>
parent 86b6c7a7
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -143,6 +143,7 @@ int blk_rq_map_user(struct request_queue *q, struct request *rq,
	return 0;
unmap_rq:
	blk_rq_unmap_user(bio);
	rq->bio = NULL;
	return ret;
}
EXPORT_SYMBOL(blk_rq_map_user);