xref: /linux/tools/perf/perf-sys.h (revision d4b996f9ef1fe83d9ce9ad5c1ca0bd8231638ce5)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _PERF_SYS_H
3 #define _PERF_SYS_H
4 
5 #include <unistd.h>
6 #include <sys/types.h>
7 #include <sys/syscall.h>
8 #include <linux/compiler.h>
9 
10 struct perf_event_attr;
11 
12 static inline int
13 sys_perf_event_open(struct perf_event_attr *attr,
14 		      pid_t pid, int cpu, int group_fd,
15 		      unsigned long flags)
16 {
17 	return syscall(__NR_perf_event_open, attr, pid, cpu,
18 		       group_fd, flags);
19 }
20 
21 #endif /* _PERF_SYS_H */
22