projects
/
linux-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ad954cb
)
bpf: Add cookie in fdinfo for tracing
author
Tao Chen
<chen.dylane@linux.dev>
Fri, 6 Jun 2025 16:58:17 +0000
(
00:58
+0800)
committer
Andrii Nakryiko
<andrii@kernel.org>
Mon, 9 Jun 2025 23:45:17 +0000
(16:45 -0700)
Add cookie in fdinfo for tracing, the info as follows:
link_type: tracing
link_id: 6
prog_tag:
9dfdf8ef453843bf
prog_id: 35
attach_type: 25
target_obj_id: 1
target_btf_id: 60355
cookie:
9007199254740992
Signed-off-by: Tao Chen <chen.dylane@linux.dev>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Link:
https://lore.kernel.org/bpf/20250606165818.3394397-4-chen.dylane@linux.dev
kernel/bpf/syscall.c
patch
|
blob
|
blame
|
history
diff --git
a/kernel/bpf/syscall.c
b/kernel/bpf/syscall.c
index 85e080c3333df7a85b0ccb9cfd9fcef07a35ee77..185cf662451d7dad92d645c30121067f4c4bf8e4 100644
(file)
--- a/
kernel/bpf/syscall.c
+++ b/
kernel/bpf/syscall.c
@@
-3403,10
+3403,12
@@
static void bpf_tracing_link_show_fdinfo(const struct bpf_link *link,
seq_printf(seq,
"attach_type:\t%d\n"
"target_obj_id:\t%u\n"
- "target_btf_id:\t%u\n",
+ "target_btf_id:\t%u\n"
+ "cookie:\t%llu\n",
tr_link->attach_type,
target_obj_id,
- target_btf_id);
+ target_btf_id,
+ tr_link->link.cookie);
}
static int bpf_tracing_link_fill_link_info(const struct bpf_link *link,