Messages in this thread Patch in this message | | | Date | Fri, 29 Aug 2014 12:37:30 -0700 | From | Andrew Morton <> | Subject | Re: [PATCH 1/3] Introduce dump_vma |
| |
On Fri, 29 Aug 2014 10:54:17 -0400 Sasha Levin <sasha.levin@oracle.com> wrote:
> Introduce a helper to dump information about a VMA, this also > makes dump_page_flags more generic and re-uses that so the > output looks very similar to dump_page: >
That's another kilobyte which we don't actually use unless CONFIG_DEBUG_VM, so how about we do
--- a/mm/page_alloc.c~introduce-dump_vma-fix +++ a/mm/page_alloc.c @@ -6683,6 +6683,8 @@ void dump_page(struct page *page, const } EXPORT_SYMBOL(dump_page); +#ifdef CONFIG_DEBUG_VM + static const struct trace_print_flags vmaflags_names[] = { {VM_READ, "read" }, {VM_WRITE, "write" }, @@ -6740,3 +6742,5 @@ void dump_vma(const struct vm_area_struc dump_flags(vma->vm_flags, vmaflags_names, ARRAY_SIZE(vmaflags_names)); } EXPORT_SYMBOL(dump_vma); + +#endif /* CONFIG_DEBUG_VM */ until someone needs it from non-debug code?
| |