All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steven Rostedt <srostedt@redhat.com>
To: Alexey Dobriyan <adobriyan@gmail.com>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>,
	linux-next@vger.kernel.org, linux-kernel@vger.kernel.org,
	mingo@redhat.com
Subject: Re: next-20081106: today's ftrace episode
Date: Thu, 06 Nov 2008 15:28:37 -0500	[thread overview]
Message-ID: <49135375.3020108@redhat.com> (raw)
In-Reply-To: <20081106201559.GA17602@x200.localdomain>

Alexey Dobriyan wrote:
>
>> basically all that would be needed in that file is this:
>>
>> #ifdef CONFIG_DYNAMIC_FTRACE
>>    extern void ftrace_nmi_enter(void);
>>    extern void ftrace_nmi_exit(void);
>> #else
>>    static inline void ftrace_nmi_enter(void) { }
>>    static inline void ftrace_nmi_exit(void) { }
>> #endif /* CONFIG_DYNAMIC_FTRACE */
>>     
>
> Oh, this is only for that.
>
> Here is patch that allows m68k to compile, I've came up with.
>   

That is quite a bit of change. I'm nervous about that because it might 
break some different combinations of configs.

I'll write up a patch that does what I propose. It has a much smaller 
impact.

-- Steve


> --- a/include/linux/ftrace.h
> +++ b/include/linux/ftrace.h
> @@ -1,14 +1,12 @@
>  #ifndef _LINUX_FTRACE_H
>  #define _LINUX_FTRACE_H
>  
> +#include <linux/kallsyms.h>
> +#ifdef CONFIG_FUNCTION_TRACER
>  #include <linux/linkage.h>
> -#include <linux/fs.h>
>  #include <linux/ktime.h>
>  #include <linux/init.h>
>  #include <linux/types.h>
> -#include <linux/kallsyms.h>
> -
> -#ifdef CONFIG_FUNCTION_TRACER
>  
>  extern int ftrace_enabled;
>  extern int
> @@ -236,7 +234,7 @@ static inline void
>  ftrace_init_module(unsigned long *start, unsigned long *end) { }
>  #endif
>  
> -
> +#ifdef CONFIG_BOOT_TRACER
>  struct boot_trace {
>  	pid_t			caller;
>  	char			func[KSYM_NAME_LEN];
> @@ -246,12 +244,10 @@ struct boot_trace {
>  	ktime_t			rettime;
>  };
>  
> -#ifdef CONFIG_BOOT_TRACER
>  extern void trace_boot(struct boot_trace *it, initcall_t fn);
>  extern void start_boot_trace(void);
>  extern void stop_boot_trace(void);
>  #else
> -static inline void trace_boot(struct boot_trace *it, initcall_t fn) { }
>  static inline void start_boot_trace(void) { }
>  static inline void stop_boot_trace(void) { }
>  #endif
> --- a/init/main.c
> +++ b/init/main.c
> @@ -728,6 +728,7 @@ core_param(initcall_debug, initcall_debug, bool, 0644);
>  
>  int do_one_initcall(initcall_t fn)
>  {
> +#ifdef CONFIG_BOOT_TRACER
>  	int count = preempt_count();
>  	ktime_t delta;
>  	char msgbuf[64];
> @@ -768,6 +769,9 @@ int do_one_initcall(initcall_t fn)
>  	}
>  
>  	return it.result;
> +#else
> +	return fn();
> +#endif
>  }
>  
>  
>   

      reply	other threads:[~2008-11-06 20:28 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-06  6:36 linux-next: Tree for November 6 Stephen Rothwell
2008-11-06 18:39 ` next-20081106: undefined reference to `__per_cpu_start' Alexey Dobriyan
2008-11-06 19:15   ` Christoph Lameter
2008-11-06 22:34     ` Alexey Dobriyan
2008-11-07 18:32       ` Christoph Lameter
2008-11-07  5:21     ` Stephen Rothwell
2008-11-07  5:44       ` Alexey Dobriyan
2008-11-07 18:28         ` Christoph Lameter
2008-11-07 18:40       ` Christoph Lameter
2008-11-18  4:33         ` linux-next: cpu_alloc tree patch (Was: Re: next-20081106: undefined reference to `__per_cpu_start') Stephen Rothwell
2008-11-19 19:18           ` Christoph Lameter
2008-11-12  7:59       ` next-20081106: undefined reference to `__per_cpu_start' Geert Uytterhoeven
2008-11-12 11:18         ` Mike Frysinger
2008-11-06 18:54 ` next-20081106: perfmon on ia64 Alexey Dobriyan
2008-11-06 20:44   ` stephane eranian
2008-11-06 19:44 ` next-20081106: today's ftrace episode Alexey Dobriyan
2008-11-06 20:03   ` Steven Rostedt
2008-11-06 20:15     ` Alexey Dobriyan
2008-11-06 20:28       ` Steven Rostedt [this message]

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=49135375.3020108@redhat.com \
    --to=srostedt@redhat.com \
    --cc=adobriyan@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=sfr@canb.auug.org.au \
    /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.