From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754017AbdFMVIG (ORCPT ); Tue, 13 Jun 2017 17:08:06 -0400 Received: from mail.kernel.org ([198.145.29.99]:48040 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752326AbdFMVIE (ORCPT ); Tue, 13 Jun 2017 17:08:04 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 528B3214EC Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=goodmis.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=rostedt@goodmis.org Date: Tue, 13 Jun 2017 17:07:55 -0400 From: Steven Rostedt To: Jeremy Linton Cc: linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, mingo@redhat.com, rusty@rustcorp.com.au, jeyu@redhat.com, kirill.shutemov@linux.intel.com, christoffer.dall@linaro.org, marc.zyngier@arm.com, jcm@jonmasters.org Subject: Re: [PATCH 10/12] tracing: Update sample file to describe the new macro Message-ID: <20170613170755.13331121@gandalf.local.home> In-Reply-To: <20170531215653.3240-11-jeremy.linton@arm.com> References: <20170531215653.3240-1-jeremy.linton@arm.com> <20170531215653.3240-11-jeremy.linton@arm.com> X-Mailer: Claws Mail 3.14.0 (GTK+ 2.24.31; x86_64-pc-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 On Wed, 31 May 2017 16:56:51 -0500 Jeremy Linton wrote: > Add a blurb in the trace sample file to describe > the macro used to add sizeof to value conversions. > > Signed-off-by: Jeremy Linton > --- > samples/trace_events/trace-events-sample.h | 7 +++++++ > 1 file changed, 7 insertions(+) > > diff --git a/samples/trace_events/trace-events-sample.h b/samples/trace_events/trace-events-sample.h > index 76a75ab..82e1e66 100644 > --- a/samples/trace_events/trace-events-sample.h > +++ b/samples/trace_events/trace-events-sample.h > @@ -225,6 +225,13 @@ TRACE_DEFINE_ENUM(TRACE_SAMPLE_FOO); > TRACE_DEFINE_ENUM(TRACE_SAMPLE_BAR); > TRACE_DEFINE_ENUM(TRACE_SAMPLE_ZOO); > > +/* > + * The same problem as above applies to sizeof(), so there is also > + * a macro to solve that problem. > + */ > + > +TRACE_DEFINE_SIZEOF(pteval_t); > + Could you add this in the example too. That is, a use case. Just having the define isn't a proper sample. You want to use it in a TP_printk() too. -- Steve > TRACE_EVENT(foo_bar, > > TP_PROTO(const char *foo, int bar, const int *lst,