aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/perf_event.h
diff options
context:
space:
mode:
authorRobert Richter <robert.richter@amd.com>2012-07-25 13:12:45 -0400
committerIngo Molnar <mingo@kernel.org>2012-09-13 10:59:48 -0400
commitbad9ac2d7f878a31cf1ae8c1ee3768077d222bcb (patch)
tree26f49a2e0824a6e6a7830e12faaeaf201b16d99b /include/linux/perf_event.h
parent35534b201c9f115c68962c095b5a9aad204d025f (diff)
perf/x86/ibs: Check syscall attribute flags
Current implementation simply ignores attribute flags. Thus, there is no notification to userland of unsupported features. Check syscall's attribute flags to let userland know if a feature is supported by the kernel. This is also needed to distinguish between future kernels what might support a feature. Cc: <stable@vger.kernel.org> v3.5.. Signed-off-by: Robert Richter <robert.richter@amd.com> Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/20120910093018.GO8285@erda.amd.com Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'include/linux/perf_event.h')
-rw-r--r--include/linux/perf_event.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h
index 33ed9d605f91..bdb41612bfec 100644
--- a/include/linux/perf_event.h
+++ b/include/linux/perf_event.h
@@ -274,6 +274,8 @@ struct perf_event_attr {
274 __u64 branch_sample_type; /* enum branch_sample_type */ 274 __u64 branch_sample_type; /* enum branch_sample_type */
275}; 275};
276 276
277#define perf_flags(attr) (*(&(attr)->read_format + 1))
278
277/* 279/*
278 * Ioctls that can be done on a perf event fd: 280 * Ioctls that can be done on a perf event fd:
279 */ 281 */