Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Mike Marshall <hubcap@omnibond.com>
int offset = 0, ret, i;
/* map the pages */
- down_write(¤t->mm->mmap_sem);
- ret = get_user_pages(current,
- current->mm,
- (unsigned long)user_desc->ptr,
- bufmap->page_count,
- 1,
- 0,
- bufmap->page_array,
- NULL);
- up_write(¤t->mm->mmap_sem);
+ ret = get_user_pages_fast((unsigned long)user_desc->ptr,
+ bufmap->page_count, 1, bufmap->page_array);
if (ret < 0)
return ret;