Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1727859
| From | Steven Rostedt <rostedt@goodmis.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v2 07/40] tracing: Apply absolute timestamps to instance max buffer |
| Date | 2017-09-07 02:50 +0200 |
| Message-ID | <umTb3-NZ-5@gated-at.bofh.it> (permalink) |
| References | <umu2Z-5m-5@gated-at.bofh.it> <umu2Z-5m-7@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Tue, 5 Sep 2017 16:57:19 -0500 Tom Zanussi <tom.zanussi@linux.intel.com> wrote: > From: Baohong Liu <baohong.liu@intel.com> > > Currently absolute timestamps are applied to both regular and max > buffers only for global trace. For instance trace, absolute > timestamps are applied only to regular buffer. But, regular and max > buffers can be swapped, for example, following a snapshot. So, for > instance trace, bad timestamps can be seen following a snapshot. > Let's apply absolute timestamps to instance max buffer as well. > > Similarly, buffer clock change is applied to instance max buffer > as well. > > Signed-off-by: Baohong Liu <baohong.liu@intel.com> > --- > kernel/trace/trace.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c > index 66d465e..719e4c1 100644 > --- a/kernel/trace/trace.c > +++ b/kernel/trace/trace.c > @@ -6223,7 +6223,7 @@ static int tracing_set_clock(struct trace_array *tr, const char *clockstr) > tracing_reset_online_cpus(&tr->trace_buffer); > > #ifdef CONFIG_TRACER_MAX_TRACE > - if (tr->flags & TRACE_ARRAY_FL_GLOBAL && tr->max_buffer.buffer) > + if (tr->max_buffer.buffer) > ring_buffer_set_clock(tr->max_buffer.buffer, trace_clocks[i].func); > tracing_reset_online_cpus(&tr->max_buffer); > #endif > @@ -6307,7 +6307,7 @@ int tracing_set_time_stamp_abs(struct trace_array *tr, bool abs) > tracing_reset_online_cpus(&tr->trace_buffer); > > #ifdef CONFIG_TRACER_MAX_TRACE > - if (tr->flags & TRACE_ARRAY_FL_GLOBAL && tr->max_buffer.buffer) > + if (tr->max_buffer.buffer) > ring_buffer_set_time_stamp_abs(tr->max_buffer.buffer, abs); > tracing_reset_online_cpus(&tr->max_buffer); > #endif Please fold this part into the previous patch. I'm adding the first part to my tree now and will start testing it tonight, and push it to Linus by the weekend. -- Steve
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH v2 07/40] tracing: Apply absolute timestamps to instance max buffer Tom Zanussi <tom.zanussi@linux.intel.com> - 2017-09-06 00:00 +0200
Re: [PATCH v2 07/40] tracing: Apply absolute timestamps to instance max buffer Steven Rostedt <rostedt@goodmis.org> - 2017-09-06 22:00 +0200
Re: [PATCH v2 07/40] tracing: Apply absolute timestamps to instance max buffer Steven Rostedt <rostedt@goodmis.org> - 2017-09-07 02:50 +0200
RE: [PATCH v2 07/40] tracing: Apply absolute timestamps to instance max buffer "Liu, Baohong" <baohong.liu@intel.com> - 2017-09-07 03:20 +0200
csiph-web