perf bpf: Add license(NAME) helper
To further reduce boilerplate. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: https://lkml.kernel.org/n/tip-vst6hj335s0ebxzqltes3nsc@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
@@ -40,5 +40,4 @@ int func(void *ctx, int err, long sec)
|
||||
return sec == 5;
|
||||
}
|
||||
|
||||
char _license[] SEC("license") = "GPL";
|
||||
int _version SEC("version") = LINUX_VERSION_CODE;
|
||||
license(GPL);
|
||||
|
@@ -1,4 +1,3 @@
|
||||
#include <bpf.h>
|
||||
|
||||
char _license[] SEC("license") = "GPL";
|
||||
int _version SEC("version") = LINUX_VERSION_CODE;
|
||||
license(GPL);
|
||||
|
Reference in New Issue
Block a user