Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751264AbdILCSz (ORCPT ); Mon, 11 Sep 2017 22:18:55 -0400 Received: from mail.kernel.org ([198.145.29.99]:60120 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751035AbdILCSx (ORCPT ); Mon, 11 Sep 2017 22:18:53 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 7E181219A9 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=mhiramat@kernel.org Date: Tue, 12 Sep 2017 11:18:50 +0900 From: Masami Hiramatsu To: Tom Zanussi Cc: rostedt@goodmis.org, tglx@linutronix.de, mhiramat@kernel.org, namhyung@kernel.org, vedang.patel@intel.com, bigeasy@linutronix.de, joel.opensrc@gmail.com, joelaf@google.com, mathieu.desnoyers@efficios.com, baohong.liu@intel.com, linux-kernel@vger.kernel.org, linux-rt-users@vger.kernel.org Subject: Re: [PATCH v2 38/40] tracing: Make tracing_set_clock() non-static Message-Id: <20170912111850.8536d7986d4f0c9dfaa210fc@kernel.org> In-Reply-To: References: X-Mailer: Sylpheed 3.5.1 (GTK+ 2.24.31; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1572 Lines: 54 On Tue, 5 Sep 2017 16:57:50 -0500 Tom Zanussi wrote: > Allow tracing code outside of trace.c to access tracing_set_clock(). > > Some applications may require a particular clock in order to function > properly, such as latency calculations. > > Also, add an accessor returning the current clock string. It seems this patch should be merged in the next patch, which is actual consumer of this API. Thank you, > > Signed-off-by: Tom Zanussi > --- > kernel/trace/trace.c | 2 +- > kernel/trace/trace.h | 1 + > 2 files changed, 2 insertions(+), 1 deletion(-) > > diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c > index d40839d..ecdf456 100644 > --- a/kernel/trace/trace.c > +++ b/kernel/trace/trace.c > @@ -6207,7 +6207,7 @@ static int tracing_clock_show(struct seq_file *m, void *v) > return 0; > } > > -static int tracing_set_clock(struct trace_array *tr, const char *clockstr) > +int tracing_set_clock(struct trace_array *tr, const char *clockstr) > { > int i; > > diff --git a/kernel/trace/trace.h b/kernel/trace/trace.h > index 7b78762..1f3443a 100644 > --- a/kernel/trace/trace.h > +++ b/kernel/trace/trace.h > @@ -288,6 +288,7 @@ enum { > extern void trace_array_put(struct trace_array *tr); > > extern int tracing_set_time_stamp_abs(struct trace_array *tr, bool abs); > +extern int tracing_set_clock(struct trace_array *tr, const char *clockstr); > > extern bool trace_clock_in_ns(struct trace_array *tr); > > -- > 1.9.3 > -- Masami Hiramatsu