* Re: [PATCH] ftrace: Fix building warning with !CONFIG_FUNCTION_TRACER
2011-07-15 5:32 [PATCH] ftrace: Fix building warning with !CONFIG_FUNCTION_TRACER Lin Ming
@ 2011-07-15 5:30 ` Américo Wang
2011-07-15 5:44 ` Lin Ming
0 siblings, 1 reply; 4+ messages in thread
From: Américo Wang @ 2011-07-15 5:30 UTC (permalink / raw)
To: Lin Ming; +Cc: Steven Rostedt, lkml
On Fri, Jul 15, 2011 at 1:32 PM, Lin Ming <ming.m.lin@intel.com> wrote:
> Commit 43dd61c(ftrace: Fix regression of :mod:module function enabling)
> causes below warning because ‘struct ftrace_hash’ is not declared with
> !CONFIG_FUNCTION_TRACER.
It is fixed,
https://lkml.org/lkml/2011/7/14/390
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH] ftrace: Fix building warning with !CONFIG_FUNCTION_TRACER
@ 2011-07-15 5:32 Lin Ming
2011-07-15 5:30 ` Américo Wang
0 siblings, 1 reply; 4+ messages in thread
From: Lin Ming @ 2011-07-15 5:32 UTC (permalink / raw)
To: Steven Rostedt; +Cc: lkml
Commit 43dd61c(ftrace: Fix regression of :mod:module function enabling)
causes below warning because ‘struct ftrace_hash’ is not declared with
!CONFIG_FUNCTION_TRACER.
In file included from /linux-2.6/include/linux/perf_event.h:508:0,
from /linux-2.6/include/linux/ftrace_event.h:8,
from /linux-2.6/include/trace/syscall.h:6,
from /linux-2.6/include/linux/syscalls.h:77,
from /linux-2.6/arch/x86/ia32/ipc32.c:4:
/linux-2.6/include/linux/ftrace.h:128:6: warning: ‘struct ftrace_hash’
declared inside parameter list [enabled by default]
/linux-2.6/include/linux/ftrace.h:128:6: warning: its scope is only this
definition or declaration, which is probably not what you want [enabled
by default]
Fixed it by declaring "struct ftrace_hash" outside of
#ifdef CONFIG_FUNCTION_TRACER
Signed-off-by: Lin Ming <ming.m.lin@intel.com>
---
include/linux/ftrace.h | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/linux/ftrace.h b/include/linux/ftrace.h
index ed0eb52..f0c0e8a 100644
--- a/include/linux/ftrace.h
+++ b/include/linux/ftrace.h
@@ -19,6 +19,8 @@
#include <asm/ftrace.h>
+struct ftrace_hash;
+
#ifdef CONFIG_FUNCTION_TRACER
extern int ftrace_enabled;
@@ -29,8 +31,6 @@ ftrace_enable_sysctl(struct ctl_table *table, int write,
typedef void (*ftrace_func_t)(unsigned long ip, unsigned long parent_ip);
-struct ftrace_hash;
-
enum {
FTRACE_OPS_FL_ENABLED = 1 << 0,
FTRACE_OPS_FL_GLOBAL = 1 << 1,
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] ftrace: Fix building warning with !CONFIG_FUNCTION_TRACER
2011-07-15 5:30 ` Américo Wang
@ 2011-07-15 5:44 ` Lin Ming
2011-07-15 10:53 ` Steven Rostedt
0 siblings, 1 reply; 4+ messages in thread
From: Lin Ming @ 2011-07-15 5:44 UTC (permalink / raw)
To: Américo Wang; +Cc: Steven Rostedt, lkml
On Fri, 2011-07-15 at 13:30 +0800, Américo Wang wrote:
> On Fri, Jul 15, 2011 at 1:32 PM, Lin Ming <ming.m.lin@intel.com> wrote:
> > Commit 43dd61c(ftrace: Fix regression of :mod:module function enabling)
> > causes below warning because ‘struct ftrace_hash’ is not declared with
> > !CONFIG_FUNCTION_TRACER.
>
> It is fixed,
> https://lkml.org/lkml/2011/7/14/390
OK.
It's not in -tip yet, so I still see the warnings.
Thanks.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] ftrace: Fix building warning with !CONFIG_FUNCTION_TRACER
2011-07-15 5:44 ` Lin Ming
@ 2011-07-15 10:53 ` Steven Rostedt
0 siblings, 0 replies; 4+ messages in thread
From: Steven Rostedt @ 2011-07-15 10:53 UTC (permalink / raw)
To: Lin Ming; +Cc: Américo Wang, lkml
On Fri, 2011-07-15 at 13:44 +0800, Lin Ming wrote:
> On Fri, 2011-07-15 at 13:30 +0800, Américo Wang wrote:
> > On Fri, Jul 15, 2011 at 1:32 PM, Lin Ming <ming.m.lin@intel.com> wrote:
> > > Commit 43dd61c(ftrace: Fix regression of :mod:module function enabling)
> > > causes below warning because ‘struct ftrace_hash’ is not declared with
> > > !CONFIG_FUNCTION_TRACER.
> >
> > It is fixed,
> > https://lkml.org/lkml/2011/7/14/390
>
> OK.
>
> It's not in -tip yet, so I still see the warnings.
Yeah, Ingo was the one to report it to me first, and I posted the fix
the next day. I also resent it last night as well.
-- Steve
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2011-07-15 10:53 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-07-15 5:32 [PATCH] ftrace: Fix building warning with !CONFIG_FUNCTION_TRACER Lin Ming
2011-07-15 5:30 ` Américo Wang
2011-07-15 5:44 ` Lin Ming
2011-07-15 10:53 ` Steven Rostedt
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.