Revert "ANDROID: mm: fix up new call to vma_merge()"

This reverts commit 7df9282d8e.
Replacing out-of-tree implementation with the upstream one.

Bug: 120441514
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Iefc8aeeea89d89b4960d51da8625cf5d48b5e98f
This commit is contained in:
Suren Baghdasaryan
2021-12-28 14:21:33 -08:00
parent bf8d29c109
commit ea253a055d

View File

@@ -1890,8 +1890,7 @@ unsigned long mmap_region(struct file *file, unsigned long addr,
*/
if (unlikely(vm_flags != vma->vm_flags && prev)) {
merge = vma_merge(mm, prev, vma->vm_start, vma->vm_end, vma->vm_flags,
NULL, vma->vm_file, vma->vm_pgoff, NULL, NULL_VM_UFFD_CTX,
vma_get_anon_name(vma));
NULL, vma->vm_file, vma->vm_pgoff, NULL, NULL_VM_UFFD_CTX);
if (merge) {
/* ->mmap() can change vma->vm_file and fput the original file. So
* fput the vma->vm_file here or we would add an extra fput for file