1*98adc743SJiri Olsa // SPDX-License-Identifier: GPL-2.0 2*98adc743SJiri Olsa #include <linux/bpf.h> 3*98adc743SJiri Olsa #include <bpf/bpf_helpers.h> 4*98adc743SJiri Olsa #include <bpf/bpf_tracing.h> 5*98adc743SJiri Olsa #include <stdbool.h> 6*98adc743SJiri Olsa #include "bpf_kfuncs.h" 7*98adc743SJiri Olsa #include "bpf_misc.h" 8*98adc743SJiri Olsa 9*98adc743SJiri Olsa char _license[] SEC("license") = "GPL"; 10*98adc743SJiri Olsa 11*98adc743SJiri Olsa __u64 uprobe_result[4]; 12*98adc743SJiri Olsa 13*98adc743SJiri Olsa SEC("uprobe.multi") uprobe_0(struct pt_regs * ctx)14*98adc743SJiri Olsaint uprobe_0(struct pt_regs *ctx) 15*98adc743SJiri Olsa { 16*98adc743SJiri Olsa uprobe_result[0]++; 17*98adc743SJiri Olsa return 0; 18*98adc743SJiri Olsa } 19*98adc743SJiri Olsa 20*98adc743SJiri Olsa SEC("uprobe.multi") uprobe_1(struct pt_regs * ctx)21*98adc743SJiri Olsaint uprobe_1(struct pt_regs *ctx) 22*98adc743SJiri Olsa { 23*98adc743SJiri Olsa uprobe_result[1]++; 24*98adc743SJiri Olsa return 0; 25*98adc743SJiri Olsa } 26*98adc743SJiri Olsa 27*98adc743SJiri Olsa SEC("uprobe.multi") uprobe_2(struct pt_regs * ctx)28*98adc743SJiri Olsaint uprobe_2(struct pt_regs *ctx) 29*98adc743SJiri Olsa { 30*98adc743SJiri Olsa uprobe_result[2]++; 31*98adc743SJiri Olsa return 0; 32*98adc743SJiri Olsa } 33*98adc743SJiri Olsa 34*98adc743SJiri Olsa SEC("uprobe.multi") uprobe_3(struct pt_regs * ctx)35*98adc743SJiri Olsaint uprobe_3(struct pt_regs *ctx) 36*98adc743SJiri Olsa { 37*98adc743SJiri Olsa uprobe_result[3]++; 38*98adc743SJiri Olsa return 0; 39*98adc743SJiri Olsa } 40