summaryrefslogtreecommitdiffstats
path: root/kernel/printk
diff options
context:
space:
mode:
authorAbderrahmane Benbachir <abderrahmane.benbachir@polymtl.ca>2018-03-23 01:33:28 +0100
committerSteven Rostedt (VMware) <rostedt@goodmis.org>2018-04-06 14:56:55 +0200
commit58eacfffc41735c9155becc73cb7f4dcc60a46a9 (patch)
tree91c31d03ea18b827060687d4cc6d61600e6f4504 /kernel/printk
parentinit, tracing: Add initcall trace events (diff)
downloadlinux-58eacfffc41735c9155becc73cb7f4dcc60a46a9.tar.xz
linux-58eacfffc41735c9155becc73cb7f4dcc60a46a9.zip
init, tracing: instrument security and console initcall trace events
Trace events have been added around the initcall functions defined in init/main.c. But console and security have their own initcalls. This adds the trace events associated for those initcall functions. Link: http://lkml.kernel.org/r/1521765208.19745.2.camel@polymtl.ca Cc: Ingo Molnar <mingo@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Abderrahmane Benbachir <abderrahmane.benbachir@polymtl.ca> Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Diffstat (limited to 'kernel/printk')
-rw-r--r--kernel/printk/printk.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/kernel/printk/printk.c b/kernel/printk/printk.c
index f274fbef821d..cb5b35341d69 100644
--- a/kernel/printk/printk.c
+++ b/kernel/printk/printk.c
@@ -52,6 +52,7 @@
#include <linux/uaccess.h>
#include <asm/sections.h>
+#include <trace/events/initcall.h>
#define CREATE_TRACE_POINTS
#include <trace/events/printk.h>
@@ -2781,6 +2782,7 @@ EXPORT_SYMBOL(unregister_console);
*/
void __init console_init(void)
{
+ int ret;
initcall_t *call;
/* Setup the default TTY line discipline. */
@@ -2791,8 +2793,11 @@ void __init console_init(void)
* inform about problems etc..
*/
call = __con_initcall_start;
+ trace_initcall_level("console");
while (call < __con_initcall_end) {
- (*call)();
+ trace_initcall_start((*call));
+ ret = (*call)();
+ trace_initcall_finish((*call), ret);
call++;
}
}