* Matthew Wilcox <willy@xxxxxxxxxxxxx> [201215 09:50]: > On Tue, Dec 15, 2020 at 09:13:00AM -0500, Liam R. Howlett wrote: > > @@ -3025,25 +3025,6 @@ SYSCALL_DEFINE5(remap_file_pages, unsigned long, start, unsigned long, size, > > > > flags &= MAP_NONBLOCK; > > flags |= MAP_SHARED | MAP_FIXED | MAP_POPULATE; > > - if (vma->vm_flags & VM_LOCKED) { > > - struct vm_area_struct *tmp; > > - flags |= MAP_LOCKED; > > I think you need to keep ^^^ that line because the vma needs to stay > mlocked. > Yes. I missed that this is transferred through by calc_vm_flag_bits() in do_mmap(). I will revise the patch. Thanks, Liam