[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1477787923-61185-37-git-send-email-davidcc@google.com>
Date: Sat, 29 Oct 2016 17:38:33 -0700
From: David Carrillo-Cisneros <davidcc@...gle.com>
To: linux-kernel@...r.kernel.org
Cc: "x86@...nel.org" <x86@...nel.org>, Ingo Molnar <mingo@...hat.com>,
Thomas Gleixner <tglx@...utronix.de>,
Andi Kleen <ak@...ux.intel.com>,
Kan Liang <kan.liang@...el.com>,
Peter Zijlstra <peterz@...radead.org>,
Vegard Nossum <vegard.nossum@...il.com>,
Marcelo Tosatti <mtosatti@...hat.com>,
Nilay Vaish <nilayvaish@...il.com>,
Borislav Petkov <bp@...e.de>,
Vikas Shivappa <vikas.shivappa@...ux.intel.com>,
Ravi V Shankar <ravi.v.shankar@...el.com>,
Fenghua Yu <fenghua.yu@...el.com>,
Paul Turner <pjt@...gle.com>,
Stephane Eranian <eranian@...gle.com>,
David Carrillo-Cisneros <davidcc@...gle.com>
Subject: [PATCH v3 36/46] perf/core: add perf_event cgroup hooks for subsystem attributes
Allow architectures to define additional attributes for the perf cgroup.
Signed-off-by: David Carrillo-Cisneros <davidcc@...gle.com>
---
include/linux/perf_event.h | 4 ++++
kernel/events/core.c | 2 ++
2 files changed, 6 insertions(+)
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h
index 3b1d542..26e6ee3 100644
--- a/include/linux/perf_event.h
+++ b/include/linux/perf_event.h
@@ -1412,4 +1412,8 @@ int perf_event_exit_cpu(unsigned int cpu);
# define perf_cgroup_arch_css_offline(css) do { } while (0)
#endif
+#ifndef PERF_CGROUP_ARCH_CGRP_SUBSYS_ATTS
+#define PERF_CGROUP_ARCH_CGRP_SUBSYS_ATTS
+#endif
+
#endif /* _LINUX_PERF_EVENT_H */
diff --git a/kernel/events/core.c b/kernel/events/core.c
index 4f43c75..b6ca765 100644
--- a/kernel/events/core.c
+++ b/kernel/events/core.c
@@ -10849,5 +10849,7 @@ struct cgroup_subsys perf_event_cgrp_subsys = {
.css_offline = perf_cgroup_css_offline,
.css_free = perf_cgroup_css_free,
.attach = perf_cgroup_attach,
+ /* Expand architecture specific attributes. */
+ PERF_CGROUP_ARCH_CGRP_SUBSYS_ATTS
};
#endif /* CONFIG_CGROUP_PERF */
--
2.8.0.rc3.226.g39d4020
Powered by blists - more mailing lists