aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorScott Wood <scottwood@freescale.com>2015-03-11 23:13:57 -0400
committerSteven Rostedt <rostedt@goodmis.org>2015-03-25 08:57:22 -0400
commitbbedb179944c29e5e449603163eec9951116fe39 (patch)
tree7ed8b4a90541e710200df3fc6a067c2dfb88f184
parent80a9b64e2c156b6523e7a01f2ba6e5d86e722814 (diff)
tracing: %pF is only for function pointers
Use %pS for actual addresses, otherwise you'll get bad output on arches like ppc64 where %pF expects a function descriptor. Link: http://lkml.kernel.org/r/1426130037-17956-22-git-send-email-scottwood@freescale.com Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
-rw-r--r--include/trace/events/btrfs.h4
-rw-r--r--include/trace/events/ext3.h2
-rw-r--r--include/trace/events/ext4.h6
-rw-r--r--include/trace/events/module.h4
-rw-r--r--include/trace/events/random.h10
-rw-r--r--kernel/trace/trace_entries.h6
-rw-r--r--tools/lib/traceevent/event-parse.c2
7 files changed, 17 insertions, 17 deletions
diff --git a/include/trace/events/btrfs.h b/include/trace/events/btrfs.h
index 1faecea101f3..572e6503394a 100644
--- a/include/trace/events/btrfs.h
+++ b/include/trace/events/btrfs.h
@@ -962,7 +962,7 @@ TRACE_EVENT(alloc_extent_state,
962 __entry->ip = IP 962 __entry->ip = IP
963 ), 963 ),
964 964
965 TP_printk("state=%p; mask = %s; caller = %pF", __entry->state, 965 TP_printk("state=%p; mask = %s; caller = %pS", __entry->state,
966 show_gfp_flags(__entry->mask), (void *)__entry->ip) 966 show_gfp_flags(__entry->mask), (void *)__entry->ip)
967); 967);
968 968
@@ -982,7 +982,7 @@ TRACE_EVENT(free_extent_state,
982 __entry->ip = IP 982 __entry->ip = IP
983 ), 983 ),
984 984
985 TP_printk(" state=%p; caller = %pF", __entry->state, 985 TP_printk(" state=%p; caller = %pS", __entry->state,
986 (void *)__entry->ip) 986 (void *)__entry->ip)
987); 987);
988 988
diff --git a/include/trace/events/ext3.h b/include/trace/events/ext3.h
index 6797b9de90ed..7f20707849bb 100644
--- a/include/trace/events/ext3.h
+++ b/include/trace/events/ext3.h
@@ -144,7 +144,7 @@ TRACE_EVENT(ext3_mark_inode_dirty,
144 __entry->ip = IP; 144 __entry->ip = IP;
145 ), 145 ),
146 146
147 TP_printk("dev %d,%d ino %lu caller %pF", 147 TP_printk("dev %d,%d ino %lu caller %pS",
148 MAJOR(__entry->dev), MINOR(__entry->dev), 148 MAJOR(__entry->dev), MINOR(__entry->dev),
149 (unsigned long) __entry->ino, (void *)__entry->ip) 149 (unsigned long) __entry->ino, (void *)__entry->ip)
150); 150);
diff --git a/include/trace/events/ext4.h b/include/trace/events/ext4.h
index 6e5abd6d38a2..47fca36ee426 100644
--- a/include/trace/events/ext4.h
+++ b/include/trace/events/ext4.h
@@ -240,7 +240,7 @@ TRACE_EVENT(ext4_mark_inode_dirty,
240 __entry->ip = IP; 240 __entry->ip = IP;
241 ), 241 ),
242 242
243 TP_printk("dev %d,%d ino %lu caller %pF", 243 TP_printk("dev %d,%d ino %lu caller %pS",
244 MAJOR(__entry->dev), MINOR(__entry->dev), 244 MAJOR(__entry->dev), MINOR(__entry->dev),
245 (unsigned long) __entry->ino, (void *)__entry->ip) 245 (unsigned long) __entry->ino, (void *)__entry->ip)
246); 246);
@@ -1762,7 +1762,7 @@ TRACE_EVENT(ext4_journal_start,
1762 __entry->rsv_blocks = rsv_blocks; 1762 __entry->rsv_blocks = rsv_blocks;
1763 ), 1763 ),
1764 1764
1765 TP_printk("dev %d,%d blocks, %d rsv_blocks, %d caller %pF", 1765 TP_printk("dev %d,%d blocks, %d rsv_blocks, %d caller %pS",
1766 MAJOR(__entry->dev), MINOR(__entry->dev), 1766 MAJOR(__entry->dev), MINOR(__entry->dev),
1767 __entry->blocks, __entry->rsv_blocks, (void *)__entry->ip) 1767 __entry->blocks, __entry->rsv_blocks, (void *)__entry->ip)
1768); 1768);
@@ -1784,7 +1784,7 @@ TRACE_EVENT(ext4_journal_start_reserved,
1784 __entry->blocks = blocks; 1784 __entry->blocks = blocks;
1785 ), 1785 ),
1786 1786
1787 TP_printk("dev %d,%d blocks, %d caller %pF", 1787 TP_printk("dev %d,%d blocks, %d caller %pS",
1788 MAJOR(__entry->dev), MINOR(__entry->dev), 1788 MAJOR(__entry->dev), MINOR(__entry->dev),
1789 __entry->blocks, (void *)__entry->ip) 1789 __entry->blocks, (void *)__entry->ip)
1790); 1790);
diff --git a/include/trace/events/module.h b/include/trace/events/module.h
index 81c4c183d348..28c45997e451 100644
--- a/include/trace/events/module.h
+++ b/include/trace/events/module.h
@@ -84,7 +84,7 @@ DECLARE_EVENT_CLASS(module_refcnt,
84 __assign_str(name, mod->name); 84 __assign_str(name, mod->name);
85 ), 85 ),
86 86
87 TP_printk("%s call_site=%pf refcnt=%d", 87 TP_printk("%s call_site=%ps refcnt=%d",
88 __get_str(name), (void *)__entry->ip, __entry->refcnt) 88 __get_str(name), (void *)__entry->ip, __entry->refcnt)
89); 89);
90 90
@@ -121,7 +121,7 @@ TRACE_EVENT(module_request,
121 __assign_str(name, name); 121 __assign_str(name, name);
122 ), 122 ),
123 123
124 TP_printk("%s wait=%d call_site=%pf", 124 TP_printk("%s wait=%d call_site=%ps",
125 __get_str(name), (int)__entry->wait, (void *)__entry->ip) 125 __get_str(name), (int)__entry->wait, (void *)__entry->ip)
126); 126);
127 127
diff --git a/include/trace/events/random.h b/include/trace/events/random.h
index 805af6db41cc..4684de344c5d 100644
--- a/include/trace/events/random.h
+++ b/include/trace/events/random.h
@@ -22,7 +22,7 @@ TRACE_EVENT(add_device_randomness,
22 __entry->IP = IP; 22 __entry->IP = IP;
23 ), 23 ),
24 24
25 TP_printk("bytes %d caller %pF", 25 TP_printk("bytes %d caller %pS",
26 __entry->bytes, (void *)__entry->IP) 26 __entry->bytes, (void *)__entry->IP)
27); 27);
28 28
@@ -43,7 +43,7 @@ DECLARE_EVENT_CLASS(random__mix_pool_bytes,
43 __entry->IP = IP; 43 __entry->IP = IP;
44 ), 44 ),
45 45
46 TP_printk("%s pool: bytes %d caller %pF", 46 TP_printk("%s pool: bytes %d caller %pS",
47 __entry->pool_name, __entry->bytes, (void *)__entry->IP) 47 __entry->pool_name, __entry->bytes, (void *)__entry->IP)
48); 48);
49 49
@@ -82,7 +82,7 @@ TRACE_EVENT(credit_entropy_bits,
82 ), 82 ),
83 83
84 TP_printk("%s pool: bits %d entropy_count %d entropy_total %d " 84 TP_printk("%s pool: bits %d entropy_count %d entropy_total %d "
85 "caller %pF", __entry->pool_name, __entry->bits, 85 "caller %pS", __entry->pool_name, __entry->bits,
86 __entry->entropy_count, __entry->entropy_total, 86 __entry->entropy_count, __entry->entropy_total,
87 (void *)__entry->IP) 87 (void *)__entry->IP)
88); 88);
@@ -207,7 +207,7 @@ DECLARE_EVENT_CLASS(random__get_random_bytes,
207 __entry->IP = IP; 207 __entry->IP = IP;
208 ), 208 ),
209 209
210 TP_printk("nbytes %d caller %pF", __entry->nbytes, (void *)__entry->IP) 210 TP_printk("nbytes %d caller %pS", __entry->nbytes, (void *)__entry->IP)
211); 211);
212 212
213DEFINE_EVENT(random__get_random_bytes, get_random_bytes, 213DEFINE_EVENT(random__get_random_bytes, get_random_bytes,
@@ -242,7 +242,7 @@ DECLARE_EVENT_CLASS(random__extract_entropy,
242 __entry->IP = IP; 242 __entry->IP = IP;
243 ), 243 ),
244 244
245 TP_printk("%s pool: nbytes %d entropy_count %d caller %pF", 245 TP_printk("%s pool: nbytes %d entropy_count %d caller %pS",
246 __entry->pool_name, __entry->nbytes, __entry->entropy_count, 246 __entry->pool_name, __entry->nbytes, __entry->entropy_count,
247 (void *)__entry->IP) 247 (void *)__entry->IP)
248); 248);
diff --git a/kernel/trace/trace_entries.h b/kernel/trace/trace_entries.h
index e2d027ac66a2..ee7b94a4810a 100644
--- a/kernel/trace/trace_entries.h
+++ b/kernel/trace/trace_entries.h
@@ -223,7 +223,7 @@ FTRACE_ENTRY(bprint, bprint_entry,
223 __dynamic_array( u32, buf ) 223 __dynamic_array( u32, buf )
224 ), 224 ),
225 225
226 F_printk("%pf: %s", 226 F_printk("%ps: %s",
227 (void *)__entry->ip, __entry->fmt), 227 (void *)__entry->ip, __entry->fmt),
228 228
229 FILTER_OTHER 229 FILTER_OTHER
@@ -238,7 +238,7 @@ FTRACE_ENTRY(print, print_entry,
238 __dynamic_array( char, buf ) 238 __dynamic_array( char, buf )
239 ), 239 ),
240 240
241 F_printk("%pf: %s", 241 F_printk("%ps: %s",
242 (void *)__entry->ip, __entry->buf), 242 (void *)__entry->ip, __entry->buf),
243 243
244 FILTER_OTHER 244 FILTER_OTHER
@@ -253,7 +253,7 @@ FTRACE_ENTRY(bputs, bputs_entry,
253 __field( const char *, str ) 253 __field( const char *, str )
254 ), 254 ),
255 255
256 F_printk("%pf: %s", 256 F_printk("%ps: %s",
257 (void *)__entry->ip, __entry->str), 257 (void *)__entry->ip, __entry->str),
258 258
259 FILTER_OTHER 259 FILTER_OTHER
diff --git a/tools/lib/traceevent/event-parse.c b/tools/lib/traceevent/event-parse.c
index afe20ed9fac8..2c0bd8f2aad0 100644
--- a/tools/lib/traceevent/event-parse.c
+++ b/tools/lib/traceevent/event-parse.c
@@ -3976,7 +3976,7 @@ static struct print_arg *make_bprint_args(char *fmt, void *data, int size, struc
3976 if (asprintf(&arg->atom.atom, "%lld", ip) < 0) 3976 if (asprintf(&arg->atom.atom, "%lld", ip) < 0)
3977 goto out_free; 3977 goto out_free;
3978 3978
3979 /* skip the first "%pf: " */ 3979 /* skip the first "%ps: " */
3980 for (ptr = fmt + 5, bptr = data + field->offset; 3980 for (ptr = fmt + 5, bptr = data + field->offset;
3981 bptr < data + size && *ptr; ptr++) { 3981 bptr < data + size && *ptr; ptr++) {
3982 int ls = 0; 3982 int ls = 0;