aboutsummaryrefslogtreecommitdiffstats
path: root/mm/mmap.c
diff options
context:
space:
mode:
Diffstat (limited to 'mm/mmap.c')
-rw-r--r--mm/mmap.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/mm/mmap.c b/mm/mmap.c
index 144b4a290f2c..724f342bcf89 100644
--- a/mm/mmap.c
+++ b/mm/mmap.c
@@ -1165,12 +1165,8 @@ out:
1165 mm->locked_vm += len >> PAGE_SHIFT; 1165 mm->locked_vm += len >> PAGE_SHIFT;
1166 make_pages_present(addr, addr + len); 1166 make_pages_present(addr, addr + len);
1167 } 1167 }
1168 if (flags & MAP_POPULATE) { 1168 if ((flags & MAP_POPULATE) && !(flags & MAP_NONBLOCK))
1169 up_write(&mm->mmap_sem); 1169 make_pages_present(addr, addr + len);
1170 sys_remap_file_pages(addr, len, 0,
1171 pgoff, flags & MAP_NONBLOCK);
1172 down_write(&mm->mmap_sem);
1173 }
1174 return addr; 1170 return addr;
1175 1171
1176unmap_and_free_vma: 1172unmap_and_free_vma: