summaryrefslogtreecommitdiffstats
path: root/init
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2017-05-03 21:41:21 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2017-05-03 21:41:21 -0400
commit4c174688ee92805aa5df6e06e5b625a3286e415c (patch)
tree78e18b242b31a3a50eda41bfdd4705e07f13647a /init
parent9c35baf6cee9a5745d55de6f9995916dde642517 (diff)
parent73a757e63114dfd765f1c5d1ff7e994f123d0234 (diff)
Merge tag 'trace-v4.12' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace
Pull tracing updates from Steven Rostedt: "New features for this release: - Pretty much a full rewrite of the processing of function plugins. i.e. echo do_IRQ:stacktrace > set_ftrace_filter - The rewrite was needed to add plugins to be unique to tracing instances. i.e. mkdir instance/foo; cd instances/foo; echo do_IRQ:stacktrace > set_ftrace_filter The old way was written very hacky. This removes a lot of those hacks. - New "function-fork" tracing option. When set, pids in the set_ftrace_pid will have their children added when the processes with their pids listed in the set_ftrace_pid file forks. - Exposure of "maxactive" for kretprobe in kprobe_events - Allow for builtin init functions to be traced by the function tracer (via the kernel command line). Module init function tracing will come in the next release. - Added more selftests, and have selftests also test in an instance" * tag 'trace-v4.12' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: (60 commits) ring-buffer: Return reader page back into existing ring buffer selftests: ftrace: Allow some event trigger tests to run in an instance selftests: ftrace: Have some basic tests run in a tracing instance too selftests: ftrace: Have event tests also run in an tracing instance selftests: ftrace: Make func_event_triggers and func_traceonoff_triggers tests do instances selftests: ftrace: Allow some tests to be run in a tracing instance tracing/ftrace: Allow for instances to trigger their own stacktrace probes tracing/ftrace: Allow for the traceonoff probe be unique to instances tracing/ftrace: Enable snapshot function trigger to work with instances tracing/ftrace: Allow instances to have their own function probes tracing/ftrace: Add a better way to pass data via the probe functions ftrace: Dynamically create the probe ftrace_ops for the trace_array tracing: Pass the trace_array into ftrace_probe_ops functions tracing: Have the trace_array hold the list of registered func probes ftrace: If the hash for a probe fails to update then free what was initialized ftrace: Have the function probes call their own function ftrace: Have each function probe use its own ftrace_ops ftrace: Have unregister_ftrace_function_probe_func() return a value ftrace: Add helper function ftrace_hash_move_and_update_ops() ftrace: Remove data field from ftrace_func_probe structure ...
Diffstat (limited to 'init')
-rw-r--r--init/main.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/init/main.c b/init/main.c
index b1b9dbf7622f..cc48053bb39f 100644
--- a/init/main.c
+++ b/init/main.c
@@ -545,6 +545,11 @@ asmlinkage __visible void __init start_kernel(void)
545 trap_init(); 545 trap_init();
546 mm_init(); 546 mm_init();
547 547
548 ftrace_init();
549
550 /* trace_printk can be enabled here */
551 early_trace_init();
552
548 /* 553 /*
549 * Set up the scheduler prior starting any interrupts (such as the 554 * Set up the scheduler prior starting any interrupts (such as the
550 * timer interrupt). Full topology setup happens at smp_init() 555 * timer interrupt). Full topology setup happens at smp_init()
@@ -570,7 +575,7 @@ asmlinkage __visible void __init start_kernel(void)
570 575
571 rcu_init(); 576 rcu_init();
572 577
573 /* trace_printk() and trace points may be used after this */ 578 /* Trace events are available after this */
574 trace_init(); 579 trace_init();
575 580
576 context_tracking_init(); 581 context_tracking_init();
@@ -670,8 +675,6 @@ asmlinkage __visible void __init start_kernel(void)
670 efi_free_boot_services(); 675 efi_free_boot_services();
671 } 676 }
672 677
673 ftrace_init();
674
675 /* Do the rest non-__init'ed, we're now alive */ 678 /* Do the rest non-__init'ed, we're now alive */
676 rest_init(); 679 rest_init();
677} 680}
@@ -959,6 +962,7 @@ static int __ref kernel_init(void *unused)
959 kernel_init_freeable(); 962 kernel_init_freeable();
960 /* need to finish all async __init code before freeing the memory */ 963 /* need to finish all async __init code before freeing the memory */
961 async_synchronize_full(); 964 async_synchronize_full();
965 ftrace_free_init_mem();
962 free_initmem(); 966 free_initmem();
963 mark_readonly(); 967 mark_readonly();
964 system_state = SYSTEM_RUNNING; 968 system_state = SYSTEM_RUNNING;