Commit 2e7a5fc8 authored by Steven Rostedt's avatar Steven Rostedt Committed by Frederic Weisbecker

parse-events: Allow '*' and '/' operations in TP_printk

Add multiply and divide operations in the printk format.
Signed-off-by: default avatarSteven Rostedt <rostedt@goodmis.org>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Arnaldo Carvalho de Melo <acme@infradead.org>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Arun Sharma <asharma@fb.com>
Cc: Namhyung Kim <namhyung.kim@lge.com>
Signed-off-by: default avatarFrederic Weisbecker <fweisbec@gmail.com>
parent b4828598
......@@ -3130,6 +3130,12 @@ eval_num_arg(void *data, int size, struct event_format *event, struct print_arg
case '+':
val = left + right;
break;
case '/':
val = left / right;
break;
case '*':
val = left * right;
break;
default:
die("unknown op '%s'", arg->op.op);
}
......
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