diff options
author | 2017-05-02 09:48:26 -0700 | |
---|---|---|
committer | 2017-05-02 09:48:26 -0700 | |
commit | 0337966d121ebebf73a1c346123e8112796e684e (patch) | |
tree | c0d4388591e72dc5a26ee976a9cbca70f6bafbbd /mm/util.c | |
parent | Input: i8042 - add Clevo P650RS to the i8042 reset list (diff) | |
parent | Input: ar1021_i2c - use BIT to check for a bit (diff) | |
download | wireguard-linux-0337966d121ebebf73a1c346123e8112796e684e.tar.xz wireguard-linux-0337966d121ebebf73a1c346123e8112796e684e.zip |
Merge branch 'next' into for-linus
Prepare input updates for 4.12 merge window.
Diffstat (limited to '')
-rw-r--r-- | mm/util.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/mm/util.c b/mm/util.c index 3cb2164f4099..656dc5e37a87 100644 --- a/mm/util.c +++ b/mm/util.c @@ -5,12 +5,15 @@ #include <linux/export.h> #include <linux/err.h> #include <linux/sched.h> +#include <linux/sched/mm.h> +#include <linux/sched/task_stack.h> #include <linux/security.h> #include <linux/swap.h> #include <linux/swapops.h> #include <linux/mman.h> #include <linux/hugetlb.h> #include <linux/vmalloc.h> +#include <linux/userfaultfd_k.h> #include <asm/sections.h> #include <linux/uaccess.h> @@ -297,14 +300,16 @@ unsigned long vm_mmap_pgoff(struct file *file, unsigned long addr, unsigned long ret; struct mm_struct *mm = current->mm; unsigned long populate; + LIST_HEAD(uf); ret = security_mmap_file(file, prot, flag); if (!ret) { if (down_write_killable(&mm->mmap_sem)) return -EINTR; ret = do_mmap_pgoff(file, addr, len, prot, flag, pgoff, - &populate); + &populate, &uf); up_write(&mm->mmap_sem); + userfaultfd_unmap_complete(mm, &uf); if (populate) mm_populate(ret, populate); } |