Home
last modified time | relevance | path

Searched refs:vmg (Results 1 – 4 of 4) sorted by relevance

/linux/tools/testing/vma/
H A Dvma.c96 static struct vm_area_struct *merge_new(struct vma_merge_struct *vmg) in merge_new() argument
102 vmg->next = vma_next(vmg->vmi); in merge_new()
103 vmg->prev = vma_prev(vmg->vmi); in merge_new()
104 vma_iter_next_range(vmg->vmi); in merge_new()
106 return vma_merge_new_range(vmg); in merge_new()
113 static struct vm_area_struct *merge_existing(struct vma_merge_struct *vmg) in merge_existing() argument
115 return vma_merge_existing_range(vmg); in merge_existing()
122 static int expand_existing(struct vma_merge_struct *vmg) in expand_existing() argument
124 return vma_expand(vmg); in expand_existing()
131 static void vmg_set_range(struct vma_merge_struct *vmg, unsigned long start, in vmg_set_range() argument
[all …]
/linux/mm/
H A Dvma.c10 static inline bool is_mergeable_vma(struct vma_merge_struct *vmg, bool merge_next) in is_mergeable_vma() argument
12 struct vm_area_struct *vma = merge_next ? vmg->next : vmg->prev; in is_mergeable_vma()
14 if (!mpol_equal(vmg->policy, vma_policy(vma))) in is_mergeable_vma()
24 if ((vma->vm_flags ^ vmg->flags) & ~VM_SOFTDIRTY) in is_mergeable_vma()
26 if (vma->vm_file != vmg->file) in is_mergeable_vma()
28 if (!is_mergeable_vm_userfaultfd_ctx(vma, vmg->uffd_ctx)) in is_mergeable_vma()
30 if (!anon_vma_name_eq(anon_vma_name(vma), vmg->anon_name)) in is_mergeable_vma()
97 static bool can_vma_merge_before(struct vma_merge_struct *vmg) in can_vma_merge_before() argument
99 pgoff_t pglen = PHYS_PFN(vmg->end - vmg->start); in can_vma_merge_before()
101 if (is_mergeable_vma(vmg, /* merge_next = */ true) && in can_vma_merge_before()
[all …]
H A Dmmap.c1377 VMG_STATE(vmg, mm, &vmi, addr, end, vm_flags, pgoff); in mmap_region()
1379 vmg.file = file; in mmap_region()
1392 vmg.next = vms.next; in mmap_region()
1393 vmg.prev = vms.prev; in mmap_region()
1396 vmg.next = vma_iter_next_rewind(&vmi, &vmg.prev); in mmap_region()
1419 vmg.flags = vm_flags; in mmap_region()
1429 vma = vma_merge_new_range(&vmg); in mmap_region()
1476 if (unlikely(vm_flags != vma->vm_flags && vmg.prev)) { in mmap_region()
1477 vmg.flags = vma->vm_flags; in mmap_region()
1479 merge = vma_merge_new_range(&vmg); in mmap_region()
[all …]
H A Dvma.h93 static inline bool vmg_nomem(struct vma_merge_struct *vmg) in vmg_nomem() argument
95 return vmg->state == VMA_MERGE_ERROR_NOMEM; in vmg_nomem()
149 int vma_expand(struct vma_merge_struct *vmg);
310 struct vm_area_struct *vma_merge_new_range(struct vma_merge_struct *vmg);