From 3e44b111b3b6ee0df4c87e55e096fe65b75b4d02 Mon Sep 17 00:00:00 2001 From: FUJITA Tomonori Date: Tue, 28 Apr 2009 20:24:29 +0200 Subject: [PATCH] --- yaml --- r: 144276 b: refs/heads/master c: 69838727bcd819a8fd73a88447801221788b0c6d h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/fs/bio.c | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 2519f9427333..68b245b2bacb 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 0191944282e84931f92915b5f06b348a92dac7e1 +refs/heads/master: 69838727bcd819a8fd73a88447801221788b0c6d diff --git a/trunk/fs/bio.c b/trunk/fs/bio.c index 7bbc98f0eda1..98711647ece4 100644 --- a/trunk/fs/bio.c +++ b/trunk/fs/bio.c @@ -817,6 +817,9 @@ struct bio *bio_copy_user_iov(struct request_queue *q, len += iov[i].iov_len; } + if (offset) + nr_pages++; + bmd = bio_alloc_map_data(nr_pages, iov_count, gfp_mask); if (!bmd) return ERR_PTR(-ENOMEM);