From 02944a23f8de51579c92247810a62f0cc7d0a4af Mon Sep 17 00:00:00 2001 From: "Matthew Wilcox (Oracle)" Date: Fri, 28 Feb 2020 15:46:27 -0500 Subject: [PATCH] extra debug --- mm/mmap.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/mm/mmap.c b/mm/mmap.c index 0ada68154f07..724bc3e9e9c3 100644 --- a/mm/mmap.c +++ b/mm/mmap.c @@ -2345,6 +2345,7 @@ found_highest: VM_BUG_ON(gap_end < gap_start); if (gap != gap_end) { + struct vm_area_struct *rb_find_vma(struct mm_struct *mm, unsigned long addr); pr_err("%s: %px Gap was found: mt %lu gap_end %lu\n", __func__, mm, gap, gap_end); pr_err("window was %lu - %lu size %lu\n", info->high_limit, @@ -2353,7 +2354,16 @@ found_highest: mas.last); pr_err("mas.index %lu align %lu offset %lu\n", mas.index, info->align_offset, info->align_mask); + pr_err("rb_find_vma find on %lu => %px (%px)\n", mas.index, + rb_find_vma(mm, mas.index), vma); mt_dump(&mm->mm_mt); + { + struct vm_area_struct *dv = mm->mmap; + while (dv) { + printk("vma %px %llu-%llu\n", dv, dv->vm_start, dv->vm_end); + dv = dv->vm_next; + } + } } VM_BUG_ON(gap != gap_end); -- 2.50.1