+ mm-cma-add-trace-events-for-cma-alloc-perf-testing-fix.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     Subject: mm: cma: Add the CMA instance name to the cma_alloc_start trace event
has been added to the -mm tree.  Its filename is
     mm-cma-add-trace-events-for-cma-alloc-perf-testing-fix.patch

This patch should soon appear at
    https://ozlabs.org/~akpm/mmots/broken-out/mm-cma-add-trace-events-for-cma-alloc-perf-testing-fix.patch
and later at
    https://ozlabs.org/~akpm/mmotm/broken-out/mm-cma-add-trace-events-for-cma-alloc-perf-testing-fix.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Georgi Djakov <georgi.djakov@xxxxxxxxxx>
Subject: mm: cma: Add the CMA instance name to the cma_alloc_start trace event

During CMA allocation, print also the name to identify the CMA instance.

Link: https://lkml.kernel.org/r/20210326155414.25006-1-georgi.djakov@xxxxxxxxxx
Signed-off-by: Georgi Djakov <georgi.djakov@xxxxxxxxxx>
Suggested-by: Minchan Kim <minchan@xxxxxxxxxx>
Acked-by: Minchan Kim <minchan@xxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 include/trace/events/cma.h |    9 ++++++---
 mm/cma.c                   |    2 +-
 2 files changed, 7 insertions(+), 4 deletions(-)

--- a/include/trace/events/cma.h~mm-cma-add-trace-events-for-cma-alloc-perf-testing-fix
+++ a/include/trace/events/cma.h
@@ -63,21 +63,24 @@ TRACE_EVENT(cma_release,
 
 TRACE_EVENT(cma_alloc_start,
 
-	TP_PROTO(unsigned int count, unsigned int align),
+	TP_PROTO(const char *name, unsigned int count, unsigned int align),
 
-	TP_ARGS(count, align),
+	TP_ARGS(name, count, align),
 
 	TP_STRUCT__entry(
+		__string(name, name)
 		__field(unsigned int, count)
 		__field(unsigned int, align)
 	),
 
 	TP_fast_assign(
+		__assign_str(name, name);
 		__entry->count = count;
 		__entry->align = align;
 	),
 
-	TP_printk("count=%u align=%u",
+	TP_printk("name=%s count=%u align=%u",
+		  __get_str(name),
 		  __entry->count,
 		  __entry->align)
 );
--- a/mm/cma.c~mm-cma-add-trace-events-for-cma-alloc-perf-testing-fix
+++ a/mm/cma.c
@@ -443,7 +443,7 @@ struct page *cma_alloc(struct cma *cma,
 	if (!count)
 		goto out;
 
-	trace_cma_alloc_start(count, align);
+	trace_cma_alloc_start(cma->name, count, align);
 
 	mask = cma_bitmap_aligned_mask(cma, align);
 	offset = cma_bitmap_aligned_offset(cma, align);
_

Patches currently in -mm which might be from georgi.djakov@xxxxxxxxxx are

mm-page_owner-record-the-timestamp-of-all-pages-during-free.patch
mm-cma-add-trace-events-for-cma-alloc-perf-testing-fix.patch




[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux