On Wed, Jul 20, 2022 at 7:06 AM Zach O'Keefe <zokeefe@xxxxxxxxxx> wrote: > > In the anonymous collapse path, huge_memory:mm_khugepaged_scan_pmd can > be used to get roughly the same information as this proposed tracepoint. > Remove it. > > Fixes: 0fff8a0de881 ("mm/madvise: add huge_memory:mm_madvise_collapse tracepoint") > Link: https://lore.kernel.org/linux-mm/Ys2vzYyVFmljt+B8@xxxxxxxxxx/ > Signed-off-by: Zach O'Keefe <zokeefe@xxxxxxxxxx> Reviewed-by: Yang Shi <shy828301@xxxxxxxxx> > --- > include/trace/events/huge_memory.h | 22 ---------------------- > mm/khugepaged.c | 2 -- > 2 files changed, 24 deletions(-) > > diff --git a/include/trace/events/huge_memory.h b/include/trace/events/huge_memory.h > index 38d339ffdb16..55392bf30a03 100644 > --- a/include/trace/events/huge_memory.h > +++ b/include/trace/events/huge_memory.h > @@ -167,27 +167,5 @@ TRACE_EVENT(mm_collapse_huge_page_swapin, > __entry->ret) > ); > > -TRACE_EVENT(mm_madvise_collapse, > - > - TP_PROTO(struct mm_struct *mm, unsigned long addr, int result), > - > - TP_ARGS(mm, addr, result), > - > - TP_STRUCT__entry(__field(struct mm_struct *, mm) > - __field(unsigned long, addr) > - __field(int, result) > - ), > - > - TP_fast_assign(__entry->mm = mm; > - __entry->addr = addr; > - __entry->result = result; > - ), > - > - TP_printk("mm=%p addr=%#lx result=%s", > - __entry->mm, > - __entry->addr, > - __print_symbolic(__entry->result, SCAN_STATUS)) > -); > - > #endif /* __HUGE_MEMORY_H */ > #include <trace/define_trace.h> > diff --git a/mm/khugepaged.c b/mm/khugepaged.c > index 70e9d9950415..28cb8429dad4 100644 > --- a/mm/khugepaged.c > +++ b/mm/khugepaged.c > @@ -2452,8 +2452,6 @@ int madvise_collapse(struct vm_area_struct *vma, struct vm_area_struct **prev, > if (!mmap_locked) > *prev = NULL; /* Tell caller we dropped mmap_lock */ > > - trace_mm_madvise_collapse(mm, addr, result); > - > switch (result) { > case SCAN_SUCCEED: > case SCAN_PMD_MAPPED: > -- > 2.37.0.170.g444d1eabd0-goog >