From: FUJITA Tomonori Date: Thu, 26 Jun 2008 17:39:23 +0000 (+0200) Subject: block: add bounce support to blk_rq_map_user_iov X-Git-Tag: v2.6.27-rc1~1114^2~17 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=07359fc61bb8ed786f96a1c24cca6f94dd17e329;p=linux-2.6 block: add bounce support to blk_rq_map_user_iov blk_rq_map_user_iov can't handle the bounce buffer (it means that the bio_map_user_iov path doesn't work with a LLD that needs GFP_DMA). This patch fixes blk_rq_map_user_iov to support the bounce buffer. Signed-off-by: FUJITA Tomonori Cc: Mike Christie Signed-off-by: Jens Axboe --- diff --git a/block/blk-map.c b/block/blk-map.c index 0b1af5a353..813011ef82 100644 --- a/block/blk-map.c +++ b/block/blk-map.c @@ -210,6 +210,7 @@ int blk_rq_map_user_iov(struct request_queue *q, struct request *rq, if (!bio_flagged(bio, BIO_USER_MAPPED)) rq->cmd_flags |= REQ_COPY_USER; + blk_queue_bounce(q, &bio); bio_get(bio); blk_rq_bio_prep(q, rq, bio); rq->buffer = rq->data = NULL;