diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2025-07-09 11:51:34 +0200 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2025-07-09 11:51:34 +0200 |
commit | 068f7b64bf2054e20bbbd0782aa11f6ff8d17105 (patch) | |
tree | f9f88dfe79f4be4789480dc22f74908b3484a8f8 /mm/vma.c | |
parent | 8959338617a85e35820e3a7fa21801cf55b068bf (diff) | |
parent | e04c78d86a9699d136910cfc0bdcf01087e3267e (diff) |
Merge v6.16-rc2 into timers/ptp
to pick up the __GENMASK() fix, otherwise the AUX clock VDSO patches fail
to compile for compat.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'mm/vma.c')
-rw-r--r-- | mm/vma.c | 23 |
1 files changed, 4 insertions, 19 deletions
@@ -967,26 +967,9 @@ static __must_check struct vm_area_struct *vma_merge_existing_range( err = dup_anon_vma(next, middle, &anon_dup); } - if (err) + if (err || commit_merge(vmg)) goto abort; - err = commit_merge(vmg); - if (err) { - VM_WARN_ON(err != -ENOMEM); - - if (anon_dup) - unlink_anon_vmas(anon_dup); - - /* - * We've cleaned up any cloned anon_vma's, no VMAs have been - * modified, no harm no foul if the user requests that we not - * report this and just give up, leaving the VMAs unmerged. - */ - if (!vmg->give_up_on_oom) - vmg->state = VMA_MERGE_ERROR_NOMEM; - return NULL; - } - khugepaged_enter_vma(vmg->target, vmg->flags); vmg->state = VMA_MERGE_SUCCESS; return vmg->target; @@ -995,6 +978,9 @@ abort: vma_iter_set(vmg->vmi, start); vma_iter_load(vmg->vmi); + if (anon_dup) + unlink_anon_vmas(anon_dup); + /* * This means we have failed to clone anon_vma's correctly, but no * actual changes to VMAs have occurred, so no harm no foul - if the @@ -3127,7 +3113,6 @@ int __vm_munmap(unsigned long start, size_t len, bool unlock) return ret; } - /* Insert vm structure into process list sorted by address * and into the inode's i_mmap tree. If vm_file is non-NULL * then i_mmap_rwsem is taken here. |