Merge tag 'pci-v5.11-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaa...
[linux-2.6-microblaze.git] / fs / aio.c
index 6a21d89..1f32da1 100644 (file)
--- a/fs/aio.c
+++ b/fs/aio.c
@@ -43,7 +43,6 @@
 #include <linux/mount.h>
 #include <linux/pseudo_fs.h>
 
-#include <asm/kmap_types.h>
 #include <linux/uaccess.h>
 #include <linux/nospec.h>
 
@@ -324,13 +323,16 @@ static void aio_free_ring(struct kioctx *ctx)
        }
 }
 
-static int aio_ring_mremap(struct vm_area_struct *vma)
+static int aio_ring_mremap(struct vm_area_struct *vma, unsigned long flags)
 {
        struct file *file = vma->vm_file;
        struct mm_struct *mm = vma->vm_mm;
        struct kioctx_table *table;
        int i, res = -EINVAL;
 
+       if (flags & MREMAP_DONTUNMAP)
+               return -EINVAL;
+
        spin_lock(&mm->ioctx_lock);
        rcu_read_lock();
        table = rcu_dereference(mm->ioctx_table);