summaryrefslogtreecommitdiffstats
path: root/block
diff options
context:
space:
mode:
Diffstat (limited to 'block')
-rw-r--r--block/blk-map.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/block/blk-map.c b/block/blk-map.c
index 0f22911f17dc..b8d2725324a6 100644
--- a/block/blk-map.c
+++ b/block/blk-map.c
@@ -93,6 +93,9 @@ int blk_rq_map_user_iov(struct request_queue *q, struct request *rq,
if (IS_ERR(bio))
return PTR_ERR(bio);
+ if (map_data && map_data->null_mapped)
+ bio->bi_flags |= (1 << BIO_NULL_MAPPED);
+
if (bio->bi_iter.bi_size != iter->count) {
/*
* Grab an extra reference to this bio, as bio_unmap_user()