summaryrefslogtreecommitdiff
path: root/arch/powerpc/include/uapi/asm/perf_event.h
diff options
context:
space:
mode:
authorMichael Ellerman <michael@ellerman.id.au>2013-07-23 12:07:45 +0400
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2013-08-01 07:11:46 +0400
commit8d7c55d01e4648605fd0dacc82d8d3989ead4db7 (patch)
tree852d175f0ddb5e40d7855fb57f7bc072f527e2b1 /arch/powerpc/include/uapi/asm/perf_event.h
parente8e813ed268d90c1377f53460527c419eb52c67a (diff)
downloadlinux-8d7c55d01e4648605fd0dacc82d8d3989ead4db7.tar.xz
powerpc/perf: Export PERF_EVENT_CONFIG_EBB_SHIFT to userspace
We use bit 63 of the event code for userspace to request that the event be counted using EBB (Event Based Branches). Export this value, making it part of the API - though only on processors that support EBB. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/include/uapi/asm/perf_event.h')
-rw-r--r--arch/powerpc/include/uapi/asm/perf_event.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/arch/powerpc/include/uapi/asm/perf_event.h b/arch/powerpc/include/uapi/asm/perf_event.h
new file mode 100644
index 000000000000..80a4d40cf5bc
--- /dev/null
+++ b/arch/powerpc/include/uapi/asm/perf_event.h
@@ -0,0 +1,18 @@
+/*
+ * Copyright 2013 Michael Ellerman, IBM Corp.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; version 2 of the
+ * License.
+ */
+
+#ifndef _UAPI_ASM_POWERPC_PERF_EVENT_H
+#define _UAPI_ASM_POWERPC_PERF_EVENT_H
+
+/*
+ * We use bit 63 of perf_event_attr.config as a flag to request EBB.
+ */
+#define PERF_EVENT_CONFIG_EBB_SHIFT 63
+
+#endif /* _UAPI_ASM_POWERPC_PERF_EVENT_H */