aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/examples/bpf/empty.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf/examples/bpf/empty.c')
-rw-r--r--tools/perf/examples/bpf/empty.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/perf/examples/bpf/empty.c b/tools/perf/examples/bpf/empty.c
index 78754df53ac1..86f97763355d 100644
--- a/tools/perf/examples/bpf/empty.c
+++ b/tools/perf/examples/bpf/empty.c
@@ -1,2 +1,4 @@
-char _license[] __attribute__((section("license"), used)) = "GPL";
-int _version __attribute__((section("version"), used)) = LINUX_VERSION_CODE;
+#include <bpf.h>
+
+char _license[] SEC("license") = "GPL";
+int _version SEC("version") = LINUX_VERSION_CODE;