On Mon, Dec 28, 2015 at 03:10:02PM -0800, Andrew Morton wrote: > On Tue, 29 Dec 2015 00:10:15 +0300 Cyrill Gorcunov <gorcu...@gmail.com> wrote: ... > > This clashes with > mm-mmapc-remove-redundant-local-variables-for-may_expand_vm.patch, > below. I resolved it thusly: > > bool may_expand_vm(struct mm_struct *mm, vm_flags_t flags, unsigned long > npages) > { > if (mm->total_vm + npages > rlimit(RLIMIT_AS) >> PAGE_SHIFT) > return false; > > if ((flags & (VM_WRITE | VM_SHARED | (VM_STACK_FLAGS & > (VM_GROWSUP | VM_GROWSDOWN)))) == VM_WRITE) > return mm->data_vm + npages <= rlimit(RLIMIT_DATA); > > return true; > }
Thanks, Andrew! -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/