Skip to content

Commit 5e37460

Browse files
Ye Binmhiramat
authored andcommitted
Documentation: tracing: add new type '%pd' and '%pD' for kprobe
Similar to printk() '%pd' is for fetch dentry's name from struct dentry's pointer, and '%pD' is for fetch file's name from struct file's pointer. Link: https://lore.kernel.org/all/[email protected]/ Signed-off-by: Ye Bin <[email protected]> Acked-by: Masami Hiramatsu (Google) <[email protected]> Signed-off-by: Masami Hiramatsu (Google) <[email protected]>
1 parent 20fe4d0 commit 5e37460

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

Documentation/trace/kprobetrace.rst

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,9 @@ Synopsis of kprobe_events
5858
NAME=FETCHARG : Set NAME as the argument name of FETCHARG.
5959
FETCHARG:TYPE : Set TYPE as the type of FETCHARG. Currently, basic types
6060
(u8/u16/u32/u64/s8/s16/s32/s64), hexadecimal types
61-
(x8/x16/x32/x64), "char", "string", "ustring", "symbol", "symstr"
62-
and bitfield are supported.
61+
(x8/x16/x32/x64), VFS layer common type(%pd/%pD), "char",
62+
"string", "ustring", "symbol", "symstr" and bitfield are
63+
supported.
6364

6465
(\*1) only for the probe on function entry (offs == 0). Note, this argument access
6566
is best effort, because depending on the argument type, it may be passed on
@@ -122,6 +123,9 @@ With 'symstr' type, you can filter the event with wildcard pattern of the
122123
symbols, and you don't need to solve symbol name by yourself.
123124
For $comm, the default type is "string"; any other type is invalid.
124125

126+
VFS layer common type(%pd/%pD) is a special type, which fetches dentry's or
127+
file's name from struct dentry's address or struct file's address.
128+
125129
.. _user_mem_access:
126130

127131
User Memory Access

0 commit comments

Comments
 (0)