Commit ef18012b authored by Steven Rostedt's avatar Steven Rostedt

tracing: remove funky whitespace in the trace code

Impact: clean up

There existed a lot of <space><tab>'s in the tracing code. This
patch removes them.
Signed-off-by: default avatarSteven Rostedt <srostedt@redhat.com>
parent 0e3d0f05
...@@ -178,8 +178,8 @@ static inline void tracepoint_synchronize_unregister(void) ...@@ -178,8 +178,8 @@ static inline void tracepoint_synchronize_unregister(void)
* * prototype, declare it via TP_PROTO(): * * prototype, declare it via TP_PROTO():
* * * *
* *
* TP_PROTO(struct rq *rq, struct task_struct *prev, * TP_PROTO(struct rq *rq, struct task_struct *prev,
* struct task_struct *next), * struct task_struct *next),
* *
* * * *
* * Define the call signature of the 'function'. * * Define the call signature of the 'function'.
...@@ -187,7 +187,7 @@ static inline void tracepoint_synchronize_unregister(void) ...@@ -187,7 +187,7 @@ static inline void tracepoint_synchronize_unregister(void)
* * TP_PROTO1/TP_PROTO2/TP_PROTO3 ugliness.) * * TP_PROTO1/TP_PROTO2/TP_PROTO3 ugliness.)
* * * *
* *
* TP_ARGS(rq, prev, next), * TP_ARGS(rq, prev, next),
* *
* * * *
* * Fast binary tracing: define the trace record via * * Fast binary tracing: define the trace record via
...@@ -229,13 +229,13 @@ static inline void tracepoint_synchronize_unregister(void) ...@@ -229,13 +229,13 @@ static inline void tracepoint_synchronize_unregister(void)
* * happens, on an active tracepoint. * * happens, on an active tracepoint.
* * * *
* *
* TP_fast_assign( * TP_fast_assign(
* memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN); * memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN);
* __entry->prev_pid = prev->pid; * __entry->prev_pid = prev->pid;
* __entry->prev_prio = prev->prio; * __entry->prev_prio = prev->prio;
* memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN); * memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN);
* __entry->next_pid = next->pid; * __entry->next_pid = next->pid;
* __entry->next_prio = next->prio; * __entry->next_prio = next->prio;
* ) * )
* *
* * * *
......
...@@ -33,7 +33,7 @@ static struct trace_array *blk_tr; ...@@ -33,7 +33,7 @@ static struct trace_array *blk_tr;
static int __read_mostly blk_tracer_enabled; static int __read_mostly blk_tracer_enabled;
/* Select an alternative, minimalistic output than the original one */ /* Select an alternative, minimalistic output than the original one */
#define TRACE_BLK_OPT_CLASSIC 0x1 #define TRACE_BLK_OPT_CLASSIC 0x1
static struct tracer_opt blk_tracer_opts[] = { static struct tracer_opt blk_tracer_opts[] = {
/* Default disable the minimalistic output */ /* Default disable the minimalistic output */
...@@ -564,7 +564,7 @@ EXPORT_SYMBOL_GPL(blk_trace_startstop); ...@@ -564,7 +564,7 @@ EXPORT_SYMBOL_GPL(blk_trace_startstop);
/** /**
* blk_trace_ioctl: - handle the ioctls associated with tracing * blk_trace_ioctl: - handle the ioctls associated with tracing
* @bdev: the block device * @bdev: the block device
* @cmd: the ioctl cmd * @cmd: the ioctl cmd
* @arg: the argument data, if any * @arg: the argument data, if any
* *
**/ **/
...@@ -1128,9 +1128,9 @@ static void blk_tracer_reset(struct trace_array *tr) ...@@ -1128,9 +1128,9 @@ static void blk_tracer_reset(struct trace_array *tr)
static struct { static struct {
const char *act[2]; const char *act[2];
int (*print)(struct trace_seq *s, const struct trace_entry *ent); int (*print)(struct trace_seq *s, const struct trace_entry *ent);
} what2act[] __read_mostly = { } what2act[] __read_mostly = {
[__BLK_TA_QUEUE] = {{ "Q", "queue" }, blk_log_generic }, [__BLK_TA_QUEUE] = {{ "Q", "queue" }, blk_log_generic },
[__BLK_TA_BACKMERGE] = {{ "M", "backmerge" }, blk_log_generic }, [__BLK_TA_BACKMERGE] = {{ "M", "backmerge" }, blk_log_generic },
[__BLK_TA_FRONTMERGE] = {{ "F", "frontmerge" }, blk_log_generic }, [__BLK_TA_FRONTMERGE] = {{ "F", "frontmerge" }, blk_log_generic },
[__BLK_TA_GETRQ] = {{ "G", "getrq" }, blk_log_generic }, [__BLK_TA_GETRQ] = {{ "G", "getrq" }, blk_log_generic },
...@@ -1229,7 +1229,7 @@ static struct tracer blk_tracer __read_mostly = { ...@@ -1229,7 +1229,7 @@ static struct tracer blk_tracer __read_mostly = {
}; };
static struct trace_event trace_blk_event = { static struct trace_event trace_blk_event = {
.type = TRACE_BLK, .type = TRACE_BLK,
.trace = blk_trace_event_print, .trace = blk_trace_event_print,
.binary = blk_trace_event_print_binary, .binary = blk_trace_event_print_binary,
}; };
......
...@@ -799,7 +799,7 @@ tracing_generic_entry_update(struct trace_entry *entry, unsigned long flags, ...@@ -799,7 +799,7 @@ tracing_generic_entry_update(struct trace_entry *entry, unsigned long flags,
entry->preempt_count = pc & 0xff; entry->preempt_count = pc & 0xff;
entry->pid = (tsk) ? tsk->pid : 0; entry->pid = (tsk) ? tsk->pid : 0;
entry->tgid = (tsk) ? tsk->tgid : 0; entry->tgid = (tsk) ? tsk->tgid : 0;
entry->flags = entry->flags =
#ifdef CONFIG_TRACE_IRQFLAGS_SUPPORT #ifdef CONFIG_TRACE_IRQFLAGS_SUPPORT
(irqs_disabled_flags(flags) ? TRACE_FLAG_IRQS_OFF : 0) | (irqs_disabled_flags(flags) ? TRACE_FLAG_IRQS_OFF : 0) |
......
...@@ -157,7 +157,7 @@ static enum print_line_t trace_branch_print(struct trace_iterator *iter, ...@@ -157,7 +157,7 @@ static enum print_line_t trace_branch_print(struct trace_iterator *iter,
static struct trace_event trace_branch_event = { static struct trace_event trace_branch_event = {
.type = TRACE_BRANCH, .type = TRACE_BRANCH,
.trace = trace_branch_print, .trace = trace_branch_print,
}; };
......
...@@ -5,23 +5,23 @@ ...@@ -5,23 +5,23 @@
* *
* static void ftrace_event_<call>(proto) * static void ftrace_event_<call>(proto)
* { * {
* event_trace_printk(_RET_IP_, "<call>: " <fmt>); * event_trace_printk(_RET_IP_, "<call>: " <fmt>);
* } * }
* *
* static int ftrace_reg_event_<call>(void) * static int ftrace_reg_event_<call>(void)
* { * {
* int ret; * int ret;
* *
* ret = register_trace_<call>(ftrace_event_<call>); * ret = register_trace_<call>(ftrace_event_<call>);
* if (!ret) * if (!ret)
* pr_info("event trace: Could not activate trace point " * pr_info("event trace: Could not activate trace point "
* "probe to <call>"); * "probe to <call>");
* return ret; * return ret;
* } * }
* *
* static void ftrace_unreg_event_<call>(void) * static void ftrace_unreg_event_<call>(void)
* { * {
* unregister_trace_<call>(ftrace_event_<call>); * unregister_trace_<call>(ftrace_event_<call>);
* } * }
* *
* For those macros defined with TRACE_FORMAT: * For those macros defined with TRACE_FORMAT:
...@@ -29,9 +29,9 @@ ...@@ -29,9 +29,9 @@
* static struct ftrace_event_call __used * static struct ftrace_event_call __used
* __attribute__((__aligned__(4))) * __attribute__((__aligned__(4)))
* __attribute__((section("_ftrace_events"))) event_<call> = { * __attribute__((section("_ftrace_events"))) event_<call> = {
* .name = "<call>", * .name = "<call>",
* .regfunc = ftrace_reg_event_<call>, * .regfunc = ftrace_reg_event_<call>,
* .unregfunc = ftrace_unreg_event_<call>, * .unregfunc = ftrace_unreg_event_<call>,
* } * }
* *
* *
...@@ -41,66 +41,66 @@ ...@@ -41,66 +41,66 @@
* *
* static void ftrace_raw_event_<call>(proto) * static void ftrace_raw_event_<call>(proto)
* { * {
* struct ring_buffer_event *event; * struct ring_buffer_event *event;
* struct ftrace_raw_<call> *entry; <-- defined in stage 1 * struct ftrace_raw_<call> *entry; <-- defined in stage 1
* unsigned long irq_flags; * unsigned long irq_flags;
* int pc; * int pc;
* *
* local_save_flags(irq_flags); * local_save_flags(irq_flags);
* pc = preempt_count(); * pc = preempt_count();
* *
* event = trace_current_buffer_lock_reserve(event_<call>.id, * event = trace_current_buffer_lock_reserve(event_<call>.id,
* sizeof(struct ftrace_raw_<call>), * sizeof(struct ftrace_raw_<call>),
* irq_flags, pc); * irq_flags, pc);
* if (!event) * if (!event)
* return; * return;
* entry = ring_buffer_event_data(event); * entry = ring_buffer_event_data(event);
* *
* <assign>; <-- Here we assign the entries by the __field and * <assign>; <-- Here we assign the entries by the __field and
* __array macros. * __array macros.
* *
* trace_current_buffer_unlock_commit(event, irq_flags, pc); * trace_current_buffer_unlock_commit(event, irq_flags, pc);
* } * }
* *
* static int ftrace_raw_reg_event_<call>(void) * static int ftrace_raw_reg_event_<call>(void)
* { * {
* int ret; * int ret;
* *
* ret = register_trace_<call>(ftrace_raw_event_<call>); * ret = register_trace_<call>(ftrace_raw_event_<call>);
* if (!ret) * if (!ret)
* pr_info("event trace: Could not activate trace point " * pr_info("event trace: Could not activate trace point "
* "probe to <call>"); * "probe to <call>");
* return ret; * return ret;
* } * }
* *
* static void ftrace_unreg_event_<call>(void) * static void ftrace_unreg_event_<call>(void)
* { * {
* unregister_trace_<call>(ftrace_raw_event_<call>); * unregister_trace_<call>(ftrace_raw_event_<call>);
* } * }
* *
* static struct trace_event ftrace_event_type_<call> = { * static struct trace_event ftrace_event_type_<call> = {
* .trace = ftrace_raw_output_<call>, <-- stage 2 * .trace = ftrace_raw_output_<call>, <-- stage 2
* }; * };
* *
* static int ftrace_raw_init_event_<call>(void) * static int ftrace_raw_init_event_<call>(void)
* { * {
* int id; * int id;
* *
* id = register_ftrace_event(&ftrace_event_type_<call>); * id = register_ftrace_event(&ftrace_event_type_<call>);
* if (!id) * if (!id)
* return -ENODEV; * return -ENODEV;
* event_<call>.id = id; * event_<call>.id = id;
* return 0; * return 0;
* } * }
* *
* static struct ftrace_event_call __used * static struct ftrace_event_call __used
* __attribute__((__aligned__(4))) * __attribute__((__aligned__(4)))
* __attribute__((section("_ftrace_events"))) event_<call> = { * __attribute__((section("_ftrace_events"))) event_<call> = {
* .name = "<call>", * .name = "<call>",
* .system = "<system>", * .system = "<system>",
* .raw_init = ftrace_raw_init_event_<call>, * .raw_init = ftrace_raw_init_event_<call>,
* .regfunc = ftrace_reg_event_<call>, * .regfunc = ftrace_reg_event_<call>,
* .unregfunc = ftrace_unreg_event_<call>, * .unregfunc = ftrace_unreg_event_<call>,
* .show_format = ftrace_format_<call>, * .show_format = ftrace_format_<call>,
* } * }
* *
...@@ -138,7 +138,7 @@ _TRACE_FORMAT(call, PARAMS(proto), PARAMS(args), PARAMS(fmt)) \ ...@@ -138,7 +138,7 @@ _TRACE_FORMAT(call, PARAMS(proto), PARAMS(args), PARAMS(fmt)) \
static struct ftrace_event_call __used \ static struct ftrace_event_call __used \
__attribute__((__aligned__(4))) \ __attribute__((__aligned__(4))) \
__attribute__((section("_ftrace_events"))) event_##call = { \ __attribute__((section("_ftrace_events"))) event_##call = { \
.name = #call, \ .name = #call, \
.system = __stringify(TRACE_SYSTEM), \ .system = __stringify(TRACE_SYSTEM), \
.regfunc = ftrace_reg_event_##call, \ .regfunc = ftrace_reg_event_##call, \
.unregfunc = ftrace_unreg_event_##call, \ .unregfunc = ftrace_unreg_event_##call, \
...@@ -163,7 +163,7 @@ static void ftrace_raw_event_##call(proto) \ ...@@ -163,7 +163,7 @@ static void ftrace_raw_event_##call(proto) \
pc = preempt_count(); \ pc = preempt_count(); \
\ \
event = trace_current_buffer_lock_reserve(event_##call.id, \ event = trace_current_buffer_lock_reserve(event_##call.id, \
sizeof(struct ftrace_raw_##call), \ sizeof(struct ftrace_raw_##call), \
irq_flags, pc); \ irq_flags, pc); \
if (!event) \ if (!event) \
return; \ return; \
...@@ -208,7 +208,7 @@ static int ftrace_raw_init_event_##call(void) \ ...@@ -208,7 +208,7 @@ static int ftrace_raw_init_event_##call(void) \
static struct ftrace_event_call __used \ static struct ftrace_event_call __used \
__attribute__((__aligned__(4))) \ __attribute__((__aligned__(4))) \
__attribute__((section("_ftrace_events"))) event_##call = { \ __attribute__((section("_ftrace_events"))) event_##call = { \
.name = #call, \ .name = #call, \
.system = __stringify(TRACE_SYSTEM), \ .system = __stringify(TRACE_SYSTEM), \
.raw_init = ftrace_raw_init_event_##call, \ .raw_init = ftrace_raw_init_event_##call, \
.regfunc = ftrace_raw_reg_event_##call, \ .regfunc = ftrace_raw_reg_event_##call, \
......
...@@ -94,7 +94,7 @@ ftrace_format_##call(struct trace_seq *s) \ ...@@ -94,7 +94,7 @@ ftrace_format_##call(struct trace_seq *s) \
static struct ftrace_event_call __used \ static struct ftrace_event_call __used \
__attribute__((__aligned__(4))) \ __attribute__((__aligned__(4))) \
__attribute__((section("_ftrace_events"))) event_##call = { \ __attribute__((section("_ftrace_events"))) event_##call = { \
.name = #call, \ .name = #call, \
.id = proto, \ .id = proto, \
.system = __stringify(TRACE_SYSTEM), \ .system = __stringify(TRACE_SYSTEM), \
.show_format = ftrace_format_##call, \ .show_format = ftrace_format_##call, \
......
...@@ -841,12 +841,12 @@ static void graph_trace_close(struct trace_iterator *iter) ...@@ -841,12 +841,12 @@ static void graph_trace_close(struct trace_iterator *iter)
} }
static struct tracer graph_trace __read_mostly = { static struct tracer graph_trace __read_mostly = {
.name = "function_graph", .name = "function_graph",
.open = graph_trace_open, .open = graph_trace_open,
.close = graph_trace_close, .close = graph_trace_close,
.wait_pipe = poll_wait_pipe, .wait_pipe = poll_wait_pipe,
.init = graph_trace_init, .init = graph_trace_init,
.reset = graph_trace_reset, .reset = graph_trace_reset,
.print_line = print_graph_function, .print_line = print_graph_function,
.print_header = print_graph_headers, .print_header = print_graph_headers,
.flags = &tracer_flags, .flags = &tracer_flags,
......
...@@ -565,7 +565,7 @@ static enum print_line_t trace_fn_bin(struct trace_iterator *iter, int flags) ...@@ -565,7 +565,7 @@ static enum print_line_t trace_fn_bin(struct trace_iterator *iter, int flags)
} }
static struct trace_event trace_fn_event = { static struct trace_event trace_fn_event = {
.type = TRACE_FN, .type = TRACE_FN,
.trace = trace_fn_trace, .trace = trace_fn_trace,
.raw = trace_fn_raw, .raw = trace_fn_raw,
.hex = trace_fn_hex, .hex = trace_fn_hex,
...@@ -696,7 +696,7 @@ static enum print_line_t trace_ctxwake_bin(struct trace_iterator *iter, ...@@ -696,7 +696,7 @@ static enum print_line_t trace_ctxwake_bin(struct trace_iterator *iter,
} }
static struct trace_event trace_ctx_event = { static struct trace_event trace_ctx_event = {
.type = TRACE_CTX, .type = TRACE_CTX,
.trace = trace_ctx_print, .trace = trace_ctx_print,
.raw = trace_ctx_raw, .raw = trace_ctx_raw,
.hex = trace_ctx_hex, .hex = trace_ctx_hex,
...@@ -704,7 +704,7 @@ static struct trace_event trace_ctx_event = { ...@@ -704,7 +704,7 @@ static struct trace_event trace_ctx_event = {
}; };
static struct trace_event trace_wake_event = { static struct trace_event trace_wake_event = {
.type = TRACE_WAKE, .type = TRACE_WAKE,
.trace = trace_wake_print, .trace = trace_wake_print,
.raw = trace_wake_raw, .raw = trace_wake_raw,
.hex = trace_wake_hex, .hex = trace_wake_hex,
...@@ -759,7 +759,7 @@ static enum print_line_t trace_special_bin(struct trace_iterator *iter, ...@@ -759,7 +759,7 @@ static enum print_line_t trace_special_bin(struct trace_iterator *iter,
} }
static struct trace_event trace_special_event = { static struct trace_event trace_special_event = {
.type = TRACE_SPECIAL, .type = TRACE_SPECIAL,
.trace = trace_special_print, .trace = trace_special_print,
.raw = trace_special_print, .raw = trace_special_print,
.hex = trace_special_hex, .hex = trace_special_hex,
...@@ -796,7 +796,7 @@ static enum print_line_t trace_stack_print(struct trace_iterator *iter, ...@@ -796,7 +796,7 @@ static enum print_line_t trace_stack_print(struct trace_iterator *iter,
} }
static struct trace_event trace_stack_event = { static struct trace_event trace_stack_event = {
.type = TRACE_STACK, .type = TRACE_STACK,
.trace = trace_stack_print, .trace = trace_stack_print,
.raw = trace_special_print, .raw = trace_special_print,
.hex = trace_special_hex, .hex = trace_special_hex,
...@@ -825,7 +825,7 @@ static enum print_line_t trace_user_stack_print(struct trace_iterator *iter, ...@@ -825,7 +825,7 @@ static enum print_line_t trace_user_stack_print(struct trace_iterator *iter,
} }
static struct trace_event trace_user_stack_event = { static struct trace_event trace_user_stack_event = {
.type = TRACE_USER_STACK, .type = TRACE_USER_STACK,
.trace = trace_user_stack_print, .trace = trace_user_stack_print,
.raw = trace_special_print, .raw = trace_special_print,
.hex = trace_special_hex, .hex = trace_special_hex,
...@@ -879,7 +879,7 @@ static enum print_line_t trace_print_raw(struct trace_iterator *iter, int flags) ...@@ -879,7 +879,7 @@ static enum print_line_t trace_print_raw(struct trace_iterator *iter, int flags)
static struct trace_event trace_print_event = { static struct trace_event trace_print_event = {
.type = TRACE_PRINT, .type = TRACE_PRINT,
.trace = trace_print_print, .trace = trace_print_print,
.raw = trace_print_raw, .raw = trace_print_raw,
}; };
......
...@@ -19,14 +19,14 @@ struct cpu_workqueue_stats { ...@@ -19,14 +19,14 @@ struct cpu_workqueue_stats {
/* Useful to know if we print the cpu headers */ /* Useful to know if we print the cpu headers */
bool first_entry; bool first_entry;
int cpu; int cpu;
pid_t pid; pid_t pid;
/* Can be inserted from interrupt or user context, need to be atomic */ /* Can be inserted from interrupt or user context, need to be atomic */
atomic_t inserted; atomic_t inserted;
/* /*
* Don't need to be atomic, works are serialized in a single workqueue thread * Don't need to be atomic, works are serialized in a single workqueue thread
* on a single CPU. * on a single CPU.
*/ */
unsigned int executed; unsigned int executed;
}; };
/* List of workqueue threads on one cpu */ /* List of workqueue threads on one cpu */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment