summaryrefslogtreecommitdiff
path: root/include/uapi/linux/perf_event.h
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2018-02-17 11:39:28 +0100
committerIngo Molnar <mingo@kernel.org>2018-02-17 11:39:28 +0100
commit7057bb975dab827997e0ca9dd92cafef0856b0cc (patch)
tree7784dc59c03f25b6bc4fa5cc12d5b61cb8b53765 /include/uapi/linux/perf_event.h
parent33ea4b24277b06dbc55d7f5772a46f029600255e (diff)
parent297f9233b53a08fd457815e19f1d6f2c3389857b (diff)
downloadlinux-next-7057bb975dab827997e0ca9dd92cafef0856b0cc.tar.gz
Merge branch 'perf/urgent' into perf/core, to pick up fixes
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'include/uapi/linux/perf_event.h')
-rw-r--r--include/uapi/linux/perf_event.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/include/uapi/linux/perf_event.h b/include/uapi/linux/perf_event.h
index 5d49cfc509e7..6f873503552d 100644
--- a/include/uapi/linux/perf_event.h
+++ b/include/uapi/linux/perf_event.h
@@ -422,6 +422,27 @@ struct perf_event_attr {
__u16 __reserved_2; /* align to __u64 */
};
+/*
+ * Structure used by below PERF_EVENT_IOC_QUERY_BPF command
+ * to query bpf programs attached to the same perf tracepoint
+ * as the given perf event.
+ */
+struct perf_event_query_bpf {
+ /*
+ * The below ids array length
+ */
+ __u32 ids_len;
+ /*
+ * Set by the kernel to indicate the number of
+ * available programs
+ */
+ __u32 prog_cnt;
+ /*
+ * User provided buffer to store program ids
+ */
+ __u32 ids[0];
+};
+
#define perf_flags(attr) (*(&(attr)->read_format + 1))
/*
@@ -437,6 +458,7 @@ struct perf_event_attr {
#define PERF_EVENT_IOC_ID _IOR('$', 7, __u64 *)
#define PERF_EVENT_IOC_SET_BPF _IOW('$', 8, __u32)
#define PERF_EVENT_IOC_PAUSE_OUTPUT _IOW('$', 9, __u32)
+#define PERF_EVENT_IOC_QUERY_BPF _IOWR('$', 10, struct perf_event_query_bpf *)
enum perf_event_ioc_flags {
PERF_IOC_FLAG_GROUP = 1U << 0,