Commit 18d45b11 authored by Ravi Bangoria's avatar Ravi Bangoria Committed by Steven Rostedt (VMware)

trace_uprobe: Use %lx to display offset

tu->offset is unsigned long, not a pointer, thus %lx should
be used to print it, not the %px.

Link: http://lkml.kernel.org/r/20180315082756.9050-1-ravi.bangoria@linux.vnet.ibm.com

Cc: stable@vger.kernel.org
Acked-by: default avatarMasami Hiramatsu <mhiramat@kernel.org>
Fixes: 0e4d819d ("trace_uprobe: Display correct offset in uprobe_events")
Suggested-by: default avatarKees Cook <keescook@chromium.org>
Signed-off-by: default avatarRavi Bangoria <ravi.bangoria@linux.vnet.ibm.com>
Signed-off-by: default avatarSteven Rostedt (VMware) <rostedt@goodmis.org>
parent f0a2aa5a
...@@ -608,7 +608,7 @@ static int probes_seq_show(struct seq_file *m, void *v) ...@@ -608,7 +608,7 @@ static int probes_seq_show(struct seq_file *m, void *v)
/* Don't print "0x (null)" when offset is 0 */ /* Don't print "0x (null)" when offset is 0 */
if (tu->offset) { if (tu->offset) {
seq_printf(m, "0x%px", (void *)tu->offset); seq_printf(m, "0x%0*lx", (int)(sizeof(void *) * 2), tu->offset);
} else { } else {
switch (sizeof(void *)) { switch (sizeof(void *)) {
case 4: case 4:
......
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