X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=samples%2Fbpf%2Ftracex2_kern.c;h=6d6eefd0d4655ed3bdcebe6bf1956a7f43a70d27;hb=1dfcd832b1a9ed45edac15b31d079b805fa0ae2a;hp=09c1adc27d426ed4adec7408a6fbae9193c39bb0;hpb=3a1ef0e03eee4c5ac30d19bb1b88e57924295810;p=deliverable%2Flinux.git diff --git a/samples/bpf/tracex2_kern.c b/samples/bpf/tracex2_kern.c index 09c1adc27d42..6d6eefd0d465 100644 --- a/samples/bpf/tracex2_kern.c +++ b/samples/bpf/tracex2_kern.c @@ -27,10 +27,10 @@ int bpf_prog2(struct pt_regs *ctx) long init_val = 1; long *value; - /* x64/s390x specific: read ip of kfree_skb caller. + /* read ip of kfree_skb caller. * non-portable version of __builtin_return_address(0) */ - bpf_probe_read(&loc, sizeof(loc), (void *)PT_REGS_RET(ctx)); + BPF_KPROBE_READ_RET_IP(loc, ctx); value = bpf_map_lookup_elem(&my_map, &loc); if (value)