* Peter Zijlstra <a.p.zijlstra@xxxxxxxxx> wrote: > > > [ v2: fix build error in the !CONFIG_EVENT_PROFILE case ] > > Signed-off-by: Ingo Molnar <mingo@xxxxxxx> > > > > > > --- > > include/linux/ftrace_event.h | 8 +++----- > > kernel/trace/trace_event_profile.c | 2 +- > > kernel/trace/trace_events.c | 2 +- > > 3 files changed, 5 insertions(+), 7 deletions(-) > > > > diff --git a/include/linux/ftrace_event.h b/include/linux/ftrace_event.h > > index 5c093ff..d7cd193 100644 > > --- a/include/linux/ftrace_event.h > > +++ b/include/linux/ftrace_event.h > > @@ -119,11 +119,9 @@ struct ftrace_event_call { > > void *filter; > > void *mod; > > > > -#ifdef CONFIG_EVENT_PROFILE > > - atomic_t profile_count; > > - int (*profile_enable)(struct ftrace_event_call *); > > - void (*profile_disable)(struct ftrace_event_call *); > > -#endif > > + atomic_t profile_count; > > + int (*profile_enable)(struct ftrace_event_call *); > > + void (*profile_disable)(struct ftrace_event_call *); > > }; > > Ah, I would have added ifdefs around the below bit. > > > diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c > > index 23d2972..e75276a 100644 > > --- a/kernel/trace/trace_events.c > > +++ b/kernel/trace/trace_events.c > > @@ -940,7 +940,7 @@ event_create_dir(struct ftrace_event_call *call, struct dentry *d_events, > > entry = trace_create_file("enable", 0644, call->dir, call, > > enable); > > > > - if (call->id) > #ifdef CONFIG_EVENT_PROFILE > > + if (call->id && call->profile_enable) > > entry = trace_create_file("id", 0444, call->dir, call, > > id); > #endif > > Like that, but I guess this works too ;-) i think CONFIG_EVENT_PROFILE should go away - it's clearly a core functionality of ftrace. Whenever we hit a Kconfig induced build breakage we should first consider reducing the Kconfig complexity a bit. Ingo -- To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html