mirror of
https://github.com/tbsdtv/linux_media.git
synced 2025-07-23 20:51:03 +02:00
mm: add vma iterator to vma_adjust() arguments
Change the vma_adjust() function definition to accept the vma iterator and pass it through to __vma_adjust(). Update fs/exec to use the new vma_adjust() function parameters. Update mm/mremap to use the new vma_adjust() function parameters. Revert the __split_vma() calls back from __vma_adjust() to vma_adjust() and pass through the vma iterator. Link: https://lkml.kernel.org/r/20230120162650.984577-37-Liam.Howlett@oracle.com Signed-off-by: Liam R. Howlett <Liam.Howlett@oracle.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
This commit is contained in:
committed by
Andrew Morton
parent
0fd5a9e2b0
commit
b373037fa9
@@ -2834,12 +2834,11 @@ extern int __vm_enough_memory(struct mm_struct *mm, long pages, int cap_sys_admi
|
||||
extern int __vma_adjust(struct vma_iterator *vmi, struct vm_area_struct *vma, unsigned long start,
|
||||
unsigned long end, pgoff_t pgoff, struct vm_area_struct *insert,
|
||||
struct vm_area_struct *expand);
|
||||
static inline int vma_adjust(struct vm_area_struct *vma, unsigned long start,
|
||||
unsigned long end, pgoff_t pgoff, struct vm_area_struct *insert)
|
||||
static inline int vma_adjust(struct vma_iterator *vmi,
|
||||
struct vm_area_struct *vma, unsigned long start, unsigned long end,
|
||||
pgoff_t pgoff, struct vm_area_struct *insert)
|
||||
{
|
||||
VMA_ITERATOR(vmi, vma->vm_mm, start);
|
||||
|
||||
return __vma_adjust(&vmi, vma, start, end, pgoff, insert, NULL);
|
||||
return __vma_adjust(vmi, vma, start, end, pgoff, insert, NULL);
|
||||
}
|
||||
extern struct vm_area_struct *vma_merge(struct vma_iterator *vmi,
|
||||
struct mm_struct *, struct vm_area_struct *prev, unsigned long addr,
|
||||
|
Reference in New Issue
Block a user