2 * bpf-script-test-kbuild.c
3 * Test include from kernel header
5 #ifndef LINUX_VERSION_CODE
6 # error Need LINUX_VERSION_CODE
7 # error Example: for 4.2 kernel, put 'clang-opt="-DLINUX_VERSION_CODE=0x40200" into llvm section of ~/.perfconfig'
9 #define SEC(NAME) __attribute__((section(NAME), used))
11 #include <uapi/linux/fs.h>
12 #include <uapi/asm/ptrace.h>
14 SEC("func=vfs_llseek")
15 int bpf_func__vfs_llseek(void *ctx
)
20 char _license
[] SEC("license") = "GPL";
21 int _version
SEC("version") = LINUX_VERSION_CODE
;