diff options
Diffstat (limited to 'kernel/trace')
| -rw-r--r-- | kernel/trace/trace_events.c | 12 | ||||
| -rw-r--r-- | kernel/trace/trace_export.c | 6 |
2 files changed, 9 insertions, 9 deletions
diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c index 35fde09b81de..5f499e0438a4 100644 --- a/kernel/trace/trace_events.c +++ b/kernel/trace/trace_events.c | |||
| @@ -1284,7 +1284,7 @@ trace_create_file_ops(struct module *mod) | |||
| 1284 | static void trace_module_add_events(struct module *mod) | 1284 | static void trace_module_add_events(struct module *mod) |
| 1285 | { | 1285 | { |
| 1286 | struct ftrace_module_file_ops *file_ops = NULL; | 1286 | struct ftrace_module_file_ops *file_ops = NULL; |
| 1287 | struct ftrace_event_call *call, *start, *end; | 1287 | struct ftrace_event_call **call, **start, **end; |
| 1288 | 1288 | ||
| 1289 | start = mod->trace_events; | 1289 | start = mod->trace_events; |
| 1290 | end = mod->trace_events + mod->num_trace_events; | 1290 | end = mod->trace_events + mod->num_trace_events; |
| @@ -1297,7 +1297,7 @@ static void trace_module_add_events(struct module *mod) | |||
| 1297 | return; | 1297 | return; |
| 1298 | 1298 | ||
| 1299 | for_each_event(call, start, end) { | 1299 | for_each_event(call, start, end) { |
| 1300 | __trace_add_event_call(call, mod, | 1300 | __trace_add_event_call(*call, mod, |
| 1301 | &file_ops->id, &file_ops->enable, | 1301 | &file_ops->id, &file_ops->enable, |
| 1302 | &file_ops->filter, &file_ops->format); | 1302 | &file_ops->filter, &file_ops->format); |
| 1303 | } | 1303 | } |
| @@ -1367,8 +1367,8 @@ static struct notifier_block trace_module_nb = { | |||
| 1367 | .priority = 0, | 1367 | .priority = 0, |
| 1368 | }; | 1368 | }; |
| 1369 | 1369 | ||
| 1370 | extern struct ftrace_event_call __start_ftrace_events[]; | 1370 | extern struct ftrace_event_call *__start_ftrace_events[]; |
| 1371 | extern struct ftrace_event_call __stop_ftrace_events[]; | 1371 | extern struct ftrace_event_call *__stop_ftrace_events[]; |
| 1372 | 1372 | ||
| 1373 | static char bootup_event_buf[COMMAND_LINE_SIZE] __initdata; | 1373 | static char bootup_event_buf[COMMAND_LINE_SIZE] __initdata; |
| 1374 | 1374 | ||
| @@ -1384,7 +1384,7 @@ __setup("trace_event=", setup_trace_event); | |||
| 1384 | 1384 | ||
| 1385 | static __init int event_trace_init(void) | 1385 | static __init int event_trace_init(void) |
| 1386 | { | 1386 | { |
| 1387 | struct ftrace_event_call *call; | 1387 | struct ftrace_event_call **call; |
| 1388 | struct dentry *d_tracer; | 1388 | struct dentry *d_tracer; |
| 1389 | struct dentry *entry; | 1389 | struct dentry *entry; |
| 1390 | struct dentry *d_events; | 1390 | struct dentry *d_events; |
| @@ -1430,7 +1430,7 @@ static __init int event_trace_init(void) | |||
| 1430 | pr_warning("tracing: Failed to allocate common fields"); | 1430 | pr_warning("tracing: Failed to allocate common fields"); |
| 1431 | 1431 | ||
| 1432 | for_each_event(call, __start_ftrace_events, __stop_ftrace_events) { | 1432 | for_each_event(call, __start_ftrace_events, __stop_ftrace_events) { |
| 1433 | __trace_add_event_call(call, NULL, &ftrace_event_id_fops, | 1433 | __trace_add_event_call(*call, NULL, &ftrace_event_id_fops, |
| 1434 | &ftrace_enable_fops, | 1434 | &ftrace_enable_fops, |
| 1435 | &ftrace_event_filter_fops, | 1435 | &ftrace_event_filter_fops, |
| 1436 | &ftrace_event_format_fops); | 1436 | &ftrace_event_format_fops); |
diff --git a/kernel/trace/trace_export.c b/kernel/trace/trace_export.c index 4b74d71705c0..bbeec31e0ae3 100644 --- a/kernel/trace/trace_export.c +++ b/kernel/trace/trace_export.c | |||
| @@ -161,13 +161,13 @@ struct ftrace_event_class event_class_ftrace_##call = { \ | |||
| 161 | .fields = LIST_HEAD_INIT(event_class_ftrace_##call.fields),\ | 161 | .fields = LIST_HEAD_INIT(event_class_ftrace_##call.fields),\ |
| 162 | }; \ | 162 | }; \ |
| 163 | \ | 163 | \ |
| 164 | struct ftrace_event_call __used \ | 164 | struct ftrace_event_call __used event_##call = { \ |
| 165 | __attribute__((__aligned__(4))) \ | ||
| 166 | __attribute__((section("_ftrace_events"))) event_##call = { \ | ||
| 167 | .name = #call, \ | 165 | .name = #call, \ |
| 168 | .event.type = etype, \ | 166 | .event.type = etype, \ |
| 169 | .class = &event_class_ftrace_##call, \ | 167 | .class = &event_class_ftrace_##call, \ |
| 170 | .print_fmt = print, \ | 168 | .print_fmt = print, \ |
| 171 | }; \ | 169 | }; \ |
| 170 | struct ftrace_event_call __used \ | ||
| 171 | __attribute__((section("_ftrace_events"))) *__event_##call = &event_##call; | ||
| 172 | 172 | ||
| 173 | #include "trace_entries.h" | 173 | #include "trace_entries.h" |
