LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH] mm: Rename mm_vmscan_lru_shrink_inactive trace event variables
@ 2019-05-22  8:44 Kirill Tkhai
  2019-05-22 10:17 ` [PATCH v2] " Kirill Tkhai
  0 siblings, 1 reply; 4+ messages in thread
From: Kirill Tkhai @ 2019-05-22  8:44 UTC (permalink / raw)
  To: akpm, mjeanson, rostedt, lttng-dev, linux-kernel, ktkhai

Rename nr_activate{0,1} into nr_activate{anon,file} since this
is exported into userspace, e.g., it's shown here:

/sys/kernel/debug/tracing/events/vmscan/mm_vmscan_lru_shrink_inactive/format.

Now we have:
field:unsigned int nr_activate0;	offset:64;	size:4;	signed:0;
field:unsigned int nr_activate1;	offset:68;	size:4;	signed:0;

The patch changes these to:
field:unsigned int nr_activate_anon;	offset:64;	size:4;	signed:0;
field:unsigned int nr_activate_file;	offset:68;	size:4;	signed:0;

which is better readable.

Suggested-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
---
 include/trace/events/vmscan.h |   10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/include/trace/events/vmscan.h b/include/trace/events/vmscan.h
index a5ab2973e8dc..c316279715f4 100644
--- a/include/trace/events/vmscan.h
+++ b/include/trace/events/vmscan.h
@@ -348,8 +348,8 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
 		__field(unsigned long, nr_writeback)
 		__field(unsigned long, nr_congested)
 		__field(unsigned long, nr_immediate)
-		__field(unsigned int, nr_activate0)
-		__field(unsigned int, nr_activate1)
+		__field(unsigned int, nr_activate_anon)
+		__field(unsigned int, nr_activate_file)
 		__field(unsigned long, nr_ref_keep)
 		__field(unsigned long, nr_unmap_fail)
 		__field(int, priority)
@@ -364,8 +364,8 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
 		__entry->nr_writeback = stat->nr_writeback;
 		__entry->nr_congested = stat->nr_congested;
 		__entry->nr_immediate = stat->nr_immediate;
-		__entry->nr_activate0 = stat->nr_activate[0];
-		__entry->nr_activate1 = stat->nr_activate[1];
+		__entry->nr_activate_anon = stat->nr_activate[0];
+		__entry->nr_activate_file = stat->nr_activate[1];
 		__entry->nr_ref_keep = stat->nr_ref_keep;
 		__entry->nr_unmap_fail = stat->nr_unmap_fail;
 		__entry->priority = priority;
@@ -377,7 +377,7 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
 		__entry->nr_scanned, __entry->nr_reclaimed,
 		__entry->nr_dirty, __entry->nr_writeback,
 		__entry->nr_congested, __entry->nr_immediate,
-		__entry->nr_activate0, __entry->nr_activate1,
+		__entry->nr_activate_anon, __entry->nr_activate_file,
 		__entry->nr_ref_keep, __entry->nr_unmap_fail,
 		__entry->priority,
 		show_reclaim_flags(__entry->reclaim_flags))


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH v2] mm: Rename mm_vmscan_lru_shrink_inactive trace event variables
  2019-05-22  8:44 [PATCH] mm: Rename mm_vmscan_lru_shrink_inactive trace event variables Kirill Tkhai
@ 2019-05-22 10:17 ` Kirill Tkhai
  2019-05-22 14:39   ` [lttng-dev] " Sebastien Boisvert
  0 siblings, 1 reply; 4+ messages in thread
From: Kirill Tkhai @ 2019-05-22 10:17 UTC (permalink / raw)
  To: akpm, mjeanson, rostedt, lttng-dev, linux-kernel

Rename nr_activate{0,1} into nr_activate{anon,file} since this
is exported into userspace, e.g., it's shown here:

/sys/kernel/debug/tracing/events/vmscan/mm_vmscan_lru_shrink_inactive/format

v2: Changed suggested person (sorry, Mathieu :))

Suggested-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
---
 include/trace/events/vmscan.h |   10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/include/trace/events/vmscan.h b/include/trace/events/vmscan.h
index a5ab2973e8dc..c316279715f4 100644
--- a/include/trace/events/vmscan.h
+++ b/include/trace/events/vmscan.h
@@ -348,8 +348,8 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
 		__field(unsigned long, nr_writeback)
 		__field(unsigned long, nr_congested)
 		__field(unsigned long, nr_immediate)
-		__field(unsigned int, nr_activate0)
-		__field(unsigned int, nr_activate1)
+		__field(unsigned int, nr_activate_anon)
+		__field(unsigned int, nr_activate_file)
 		__field(unsigned long, nr_ref_keep)
 		__field(unsigned long, nr_unmap_fail)
 		__field(int, priority)
@@ -364,8 +364,8 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
 		__entry->nr_writeback = stat->nr_writeback;
 		__entry->nr_congested = stat->nr_congested;
 		__entry->nr_immediate = stat->nr_immediate;
-		__entry->nr_activate0 = stat->nr_activate[0];
-		__entry->nr_activate1 = stat->nr_activate[1];
+		__entry->nr_activate_anon = stat->nr_activate[0];
+		__entry->nr_activate_file = stat->nr_activate[1];
 		__entry->nr_ref_keep = stat->nr_ref_keep;
 		__entry->nr_unmap_fail = stat->nr_unmap_fail;
 		__entry->priority = priority;
@@ -377,7 +377,7 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
 		__entry->nr_scanned, __entry->nr_reclaimed,
 		__entry->nr_dirty, __entry->nr_writeback,
 		__entry->nr_congested, __entry->nr_immediate,
-		__entry->nr_activate0, __entry->nr_activate1,
+		__entry->nr_activate_anon, __entry->nr_activate_file,
 		__entry->nr_ref_keep, __entry->nr_unmap_fail,
 		__entry->priority,
 		show_reclaim_flags(__entry->reclaim_flags))

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [lttng-dev] [PATCH v2] mm: Rename mm_vmscan_lru_shrink_inactive trace event variables
  2019-05-22 10:17 ` [PATCH v2] " Kirill Tkhai
@ 2019-05-22 14:39   ` Sebastien Boisvert
  2019-05-23 16:13     ` [PATCH v3] " Kirill Tkhai
  0 siblings, 1 reply; 4+ messages in thread
From: Sebastien Boisvert @ 2019-05-22 14:39 UTC (permalink / raw)
  To: Kirill Tkhai, akpm, mjeanson, rostedt, lttng-dev, linux-kernel



On 2019-05-22 6:17 a.m., Kirill Tkhai wrote:
> Rename nr_activate{0,1} into nr_activate{anon,file} since this

Rename nr_activate{0,1} into nr_activate{anon,file}
                                        ^
                                         add an underscore here
 (nr_activate_anon, nr_activate_file).


> is exported into userspace, e.g., it's shown here:
> 
> /sys/kernel/debug/tracing/events/vmscan/mm_vmscan_lru_shrink_inactive/format
> 
> v2: Changed suggested person (sorry, Mathieu :))
> 
> Suggested-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
> Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
> ---
>  include/trace/events/vmscan.h |   10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/include/trace/events/vmscan.h b/include/trace/events/vmscan.h
> index a5ab2973e8dc..c316279715f4 100644
> --- a/include/trace/events/vmscan.h
> +++ b/include/trace/events/vmscan.h
> @@ -348,8 +348,8 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
>  		__field(unsigned long, nr_writeback)
>  		__field(unsigned long, nr_congested)
>  		__field(unsigned long, nr_immediate)
> -		__field(unsigned int, nr_activate0)
> -		__field(unsigned int, nr_activate1)
> +		__field(unsigned int, nr_activate_anon)
> +		__field(unsigned int, nr_activate_file)
>  		__field(unsigned long, nr_ref_keep)
>  		__field(unsigned long, nr_unmap_fail)
>  		__field(int, priority)
> @@ -364,8 +364,8 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
>  		__entry->nr_writeback = stat->nr_writeback;
>  		__entry->nr_congested = stat->nr_congested;
>  		__entry->nr_immediate = stat->nr_immediate;
> -		__entry->nr_activate0 = stat->nr_activate[0];
> -		__entry->nr_activate1 = stat->nr_activate[1];
> +		__entry->nr_activate_anon = stat->nr_activate[0];
> +		__entry->nr_activate_file = stat->nr_activate[1];
>  		__entry->nr_ref_keep = stat->nr_ref_keep;
>  		__entry->nr_unmap_fail = stat->nr_unmap_fail;
>  		__entry->priority = priority;
> @@ -377,7 +377,7 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
>  		__entry->nr_scanned, __entry->nr_reclaimed,
>  		__entry->nr_dirty, __entry->nr_writeback,
>  		__entry->nr_congested, __entry->nr_immediate,
> -		__entry->nr_activate0, __entry->nr_activate1,
> +		__entry->nr_activate_anon, __entry->nr_activate_file,
>  		__entry->nr_ref_keep, __entry->nr_unmap_fail,
>  		__entry->priority,
>  		show_reclaim_flags(__entry->reclaim_flags))
> _______________________________________________
> lttng-dev mailing list
> lttng-dev@lists.lttng.org
> https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH v3] mm: Rename mm_vmscan_lru_shrink_inactive trace event variables
  2019-05-22 14:39   ` [lttng-dev] " Sebastien Boisvert
@ 2019-05-23 16:13     ` Kirill Tkhai
  0 siblings, 0 replies; 4+ messages in thread
From: Kirill Tkhai @ 2019-05-23 16:13 UTC (permalink / raw)
  To: Sebastien Boisvert, akpm, mjeanson, rostedt, lttng-dev, linux-kernel

Rename nr_activate{0,1} into nr_activate_{anon,file} since this
is exported into userspace, e.g., it's shown here:

/sys/kernel/debug/tracing/events/vmscan/mm_vmscan_lru_shrink_inactive/format

v3: Fix comment
v2: Changed suggested person

Suggested-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
---
 include/trace/events/vmscan.h |   10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/include/trace/events/vmscan.h b/include/trace/events/vmscan.h
index a5ab2973e8dc..c316279715f4 100644
--- a/include/trace/events/vmscan.h
+++ b/include/trace/events/vmscan.h
@@ -348,8 +348,8 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
 		__field(unsigned long, nr_writeback)
 		__field(unsigned long, nr_congested)
 		__field(unsigned long, nr_immediate)
-		__field(unsigned int, nr_activate0)
-		__field(unsigned int, nr_activate1)
+		__field(unsigned int, nr_activate_anon)
+		__field(unsigned int, nr_activate_file)
 		__field(unsigned long, nr_ref_keep)
 		__field(unsigned long, nr_unmap_fail)
 		__field(int, priority)
@@ -364,8 +364,8 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
 		__entry->nr_writeback = stat->nr_writeback;
 		__entry->nr_congested = stat->nr_congested;
 		__entry->nr_immediate = stat->nr_immediate;
-		__entry->nr_activate0 = stat->nr_activate[0];
-		__entry->nr_activate1 = stat->nr_activate[1];
+		__entry->nr_activate_anon = stat->nr_activate[0];
+		__entry->nr_activate_file = stat->nr_activate[1];
 		__entry->nr_ref_keep = stat->nr_ref_keep;
 		__entry->nr_unmap_fail = stat->nr_unmap_fail;
 		__entry->priority = priority;
@@ -377,7 +377,7 @@ TRACE_EVENT(mm_vmscan_lru_shrink_inactive,
 		__entry->nr_scanned, __entry->nr_reclaimed,
 		__entry->nr_dirty, __entry->nr_writeback,
 		__entry->nr_congested, __entry->nr_immediate,
-		__entry->nr_activate0, __entry->nr_activate1,
+		__entry->nr_activate_anon, __entry->nr_activate_file,
 		__entry->nr_ref_keep, __entry->nr_unmap_fail,
 		__entry->priority,
 		show_reclaim_flags(__entry->reclaim_flags))

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-05-23 16:13 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-22  8:44 [PATCH] mm: Rename mm_vmscan_lru_shrink_inactive trace event variables Kirill Tkhai
2019-05-22 10:17 ` [PATCH v2] " Kirill Tkhai
2019-05-22 14:39   ` [lttng-dev] " Sebastien Boisvert
2019-05-23 16:13     ` [PATCH v3] " Kirill Tkhai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).