[<prev] [next>] [day] [month] [year] [list]
Message-Id: <1380724087-13927-15-git-send-email-jack@suse.cz>
Date: Wed, 2 Oct 2013 16:27:55 +0200
From: Jan Kara <jack@...e.cz>
To: LKML <linux-kernel@...r.kernel.org>
Cc: linux-mm@...ck.org, Jan Kara <jack@...e.cz>,
Trond Myklebust <Trond.Myklebust@...app.com>,
linux-nfs@...r.kernel.org
Subject: [PATCH 14/26] nfs: Convert direct IO to use get_user_pages_fast()
CC: Trond Myklebust <Trond.Myklebust@...app.com>
CC: linux-nfs@...r.kernel.org
Signed-off-by: Jan Kara <jack@...e.cz>
---
fs/nfs/direct.c | 12 ++++--------
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/fs/nfs/direct.c b/fs/nfs/direct.c
index 91ff089d3412..1aaf4aa2b3d7 100644
--- a/fs/nfs/direct.c
+++ b/fs/nfs/direct.c
@@ -337,10 +337,8 @@ static ssize_t nfs_direct_read_schedule_segment(struct nfs_pageio_descriptor *de
if (!pagevec)
break;
if (uio) {
- down_read(¤t->mm->mmap_sem);
- result = get_user_pages(current, current->mm, user_addr,
- npages, 1, 0, pagevec, NULL);
- up_read(¤t->mm->mmap_sem);
+ result = get_user_pages_fast(user_addr, npages, 1,
+ pagevec);
if (result < 0)
break;
} else {
@@ -658,10 +656,8 @@ static ssize_t nfs_direct_write_schedule_segment(struct nfs_pageio_descriptor *d
break;
if (uio) {
- down_read(¤t->mm->mmap_sem);
- result = get_user_pages(current, current->mm, user_addr,
- npages, 0, 0, pagevec, NULL);
- up_read(¤t->mm->mmap_sem);
+ result = get_user_pages_fast(user_addr, npages, 0,
+ pagevec);
if (result < 0)
break;
} else {
--
1.8.1.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists