lkml.org 
[lkml]   [2015]   [Jan]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/2] tracing: Move enabling tracepoints to just after rcu_init()
Ping...

On 2015/1/9 12:06, Wang Nan wrote:
> Hi Steven Rostedt,
>
> During studying your code we find a problem, please see below.
>
>>
>> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
>>
>> Enabling tracepoints at boot up can be very useful. The tracepoint
>> can be initialized right after RCU has been. There's no need to
>> wait for the early_initcall() to be called. That's too late for some
>> things that can use tracepoints for debugging. Move the logic to
>> enable tracepoints out of the initcalls and into init/main.c to
>> right after rcu_init().
>>
>> This also allows trace_printk() to be used early too.
>>
>> Link: http://lkml.kernel.org/r/alpine.DEB.2.11.1412121539300.16494@nanos
>> Link: http://lkml.kernel.org/r/20141214164104.307127356@goodmis.org
>>
>> Reviewed-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
>> Suggested-by: Thomas Gleixner <tglx@linutronix.de>
>> Tested-by: Thomas Gleixner <tglx@linutronix.de>
>> Acked-by: Thomas Gleixner <tglx@linutronix.de>
>> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
>
> [...]
>
>> +void __init trace_init(void)
>> +{
>> + tracer_alloc_buffers();
>> + init_ftrace_syscalls();
>> + trace_event_init();
>> +}
>> +
>
> [...]
>
>> +
>> +void __init trace_event_init(void)
>> +{
>> + event_trace_memsetup();
>> + init_ftrace_syscalls();
>> + event_trace_enable();
>> +}
>> +
>
> init_ftrace_syscalls() get called twice by trace_init() and trace_event_init(), some resources are wasted.
> At lease one of them can be removed.
>
> In addition, could you please have a look at my early kprobe patch series?
>
> http://lists.infradead.org/pipermail/linux-arm-kernel/2015-January/313835.html
>
> Which enables kprobe very early, even before memory initialized. I think it is possible to combine these
> early tracing facilities together.
>
> Thank you!
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
>




\
 
 \ /
  Last update: 2015-01-14 01:21    [W:0.054 / U:0.996 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site