22 lines · c
1/* SPDX-License-Identifier: GPL-2.0 */2#ifndef _PERF_SYS_H3#define _PERF_SYS_H4 5#include <unistd.h>6#include <sys/types.h>7#include <sys/syscall.h>8#include <linux/compiler.h>9 10struct perf_event_attr;11 12static inline int13sys_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