lkml.org 
[lkml]   [2017]   [May]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Subject[PATCH 1/7] kernel-trace: Combine two function calls into one in hist_trigger_entry_print()
From
Date
From: Markus Elfring <elfring@users.sourceforge.net>
Date: Fri, 5 May 2017 19:40:39 +0200

A bit of data was put into a sequence by two separate function calls.
Print the same data by a single function call instead.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
---
kernel/trace/trace_events_hist.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/kernel/trace/trace_events_hist.c b/kernel/trace/trace_events_hist.c
index 1c21d0e2a145..94999934ffd5 100644
--- a/kernel/trace/trace_events_hist.c
+++ b/kernel/trace/trace_events_hist.c
@@ -1017,7 +1017,5 @@ hist_trigger_entry_print(struct seq_file *m,

- seq_puts(m, "}");
-
- seq_printf(m, " hitcount: %10llu",
+ seq_printf(m, "} hitcount: %10llu",
tracing_map_read_sum(elt, HITCOUNT_IDX));

for (i = 1; i < hist_data->n_vals; i++) {
--
2.12.2
\
 
 \ /
  Last update: 2017-05-05 23:02    [W:0.099 / U:0.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site