From: Ingo Molnar <mingo@elte.hu>
To: Steven Noonan <steven@uplinklabs.net>
Cc: Andrew Morton <akpm@linux-foundation.org>, linux-kernel@vger.kernel.org
Subject: Re: [PATCH -tip FIXED] ftrace: add nop tracer
Date: Sat, 20 Sep 2008 08:16:59 +0200 [thread overview]
Message-ID: <20080920061659.GF25713@elte.hu> (raw)
In-Reply-To: <f488382f0809191635o45f3ed17vc23380eab41b2878@mail.gmail.com>
* Steven Noonan <steven@uplinklabs.net> wrote:
> On Fri, Sep 19, 2008 at 2:23 PM, Andrew Morton
> <akpm@linux-foundation.org> wrote:
> > On Fri, 19 Sep 2008 03:06:43 -0700
> > Steven Noonan <steven@uplinklabs.net> wrote:
> >
> >> --- a/kernel/trace/trace.h
> >> +++ b/kernel/trace/trace.h
> >> @@ -339,6 +339,10 @@ extern int trace_selftest_startup_preemptirqsoff(struct tracer *trace,
> >> extern int trace_selftest_startup_wakeup(struct tracer *trace,
> >> struct trace_array *tr);
> >> #endif
> >> +#ifdef CONFIG_NOP_TRACER
> >> +extern int trace_selftest_startup_nop(struct tracer *trace,
> >> + struct trace_array *tr);
> >> +#endif
> >> #ifdef CONFIG_CONTEXT_SWITCH_TRACER
> >> extern int trace_selftest_startup_sched_switch(struct tracer *trace,
> >> struct trace_array *tr);
> >
> > Consider omitting the ifdefs around the declarations.
> >
> > pro: the code looks nicer and is less likely to suffer build errors
> > with weird config combinations.
> >
> > con: build errors are reported at link-time rather than at compile-time.
> >
> > Personally, I think pro>con here.
> >
>
> I merely based this on one of the other tracers, so the ifdefs are
> basically copied and renamed.
yeah. Feel free to send a separate patch that implements Andrew's
clean-up suggestion. I agree that pro>con.
Ingo
next prev parent reply other threads:[~2008-09-20 6:17 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-09-19 10:06 [PATCH -tip FIXED] ftrace: add nop tracer Steven Noonan
2008-09-19 10:43 ` Ingo Molnar
2008-09-19 10:48 ` Frédéric Weisbecker
2008-09-19 11:04 ` Ingo Molnar
2008-09-19 11:30 ` Frédéric Weisbecker
2008-09-19 21:23 ` Andrew Morton
2008-09-19 23:35 ` Steven Noonan
2008-09-20 6:16 ` Ingo Molnar [this message]
2008-09-20 7:33 ` Steven Noonan
2008-09-20 7:47 ` Andrew Morton
2008-09-20 11:31 ` Ingo Molnar
2008-09-20 15:04 ` Steven Noonan
2008-09-20 8:00 ` [PATCH] ftrace: mcount_addr defined but not used Steven Noonan
2008-09-20 8:00 ` [PATCH] trace: remove pointless ifdefs Steven Noonan
2008-09-20 11:33 ` Ingo Molnar
2008-09-20 8:31 ` [PATCH] ftrace: mcount_addr defined but not used Steven Noonan
2008-09-20 8:33 ` Steven Noonan
2008-09-20 11:33 ` Ingo Molnar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080920061659.GF25713@elte.hu \
--to=mingo@elte.hu \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=steven@uplinklabs.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.