1 // SPDX-License-Identifier: GPL-2.0
2 // Copyright (c) 2017 Facebook
4 #include <linux/ptrace.h>
6 #include <bpf/bpf_helpers.h>
11 int uretprobe_res
= 0;
13 SEC("kprobe/sys_nanosleep")
14 int handle_kprobe(struct pt_regs
*ctx
)
20 SEC("kretprobe/sys_nanosleep")
21 int handle_kretprobe(struct pt_regs
*ctx
)
27 SEC("uprobe/trigger_func")
28 int handle_uprobe(struct pt_regs
*ctx
)
34 SEC("uretprobe/trigger_func")
35 int handle_uretprobe(struct pt_regs
*ctx
)
41 char _license
[] SEC("license") = "GPL";