1 // SPDX-License-Identifier: GPL-2.0
2 /* Copyright (c) 2020 Facebook */
5 #include <bpf/bpf_helpers.h>
6 #include <bpf/bpf_tracing.h>
9 __u32 on_cpu = 0xffffffff;
11 SEC("raw_tp/task_rename")
12 int BPF_PROG(rename, struct task_struct *task, char *comm)
16 if ((__u64) task == 0x1234ULL && (__u64) comm == 0x5678ULL) {
17 on_cpu = bpf_get_smp_processor_id();
18 return (long)task + (long)comm;
24 char _license[] SEC("license") = "GPL";