From: Peter Zijlstra <peterz@infradead.org>
To: Namhyung Kim <namhyung@kernel.org>
Cc: Ingo Molnar <mingo@kernel.org>,
Arnaldo Carvalho de Melo <acme@kernel.org>,
Jiri Olsa <jolsa@redhat.com>,
Alexander Shishkin <alexander.shishkin@linux.intel.com>,
Mark Rutland <mark.rutland@arm.com>,
Stephane Eranian <eranian@google.com>,
LKML <linux-kernel@vger.kernel.org>,
linux-perf-users@vger.kernel.org, Tejun Heo <tj@kernel.org>,
Li Zefan <lizefan@huawei.com>,
Johannes Weiner <hannes@cmpxchg.org>,
Adrian Hunter <adrian.hunter@intel.com>
Subject: Re: [PATCH 1/9] perf/core: Add PERF_RECORD_CGROUP event
Date: Tue, 7 Jan 2020 13:51:31 +0100 [thread overview]
Message-ID: <20200107125131.GZ2844@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <20191223060759.841176-2-namhyung@kernel.org>
On Mon, Dec 23, 2019 at 03:07:51PM +0900, Namhyung Kim wrote:
> @@ -7564,6 +7567,105 @@ void perf_event_namespaces(struct task_struct *task)
> NULL);
> }
>
> +/*
> + * cgroup tracking
> + */
> +#ifdef CONFIG_CGROUPS
> +
<snip>
> +
> +#endif
> +
> /*
> * mmap tracking
> */
> @@ -12581,6 +12685,12 @@ static void perf_cgroup_css_free(struct cgroup_subsys_state *css)
> kfree(jc);
> }
>
> +static int perf_cgroup_css_online(struct cgroup_subsys_state *css)
> +{
> + perf_event_cgroup(css->cgroup);
> + return 0;
> +}
> +
> static int __perf_cgroup_move(void *info)
> {
> struct task_struct *task = info;
> @@ -12602,6 +12712,7 @@ static void perf_cgroup_attach(struct cgroup_taskset *tset)
> struct cgroup_subsys perf_event_cgrp_subsys = {
> .css_alloc = perf_cgroup_css_alloc,
> .css_free = perf_cgroup_css_free,
> + .css_online = perf_cgroup_css_online,
> .attach = perf_cgroup_attach,
> /*
> * Implicitly enable on dfl hierarchy so that perf events can
CONFIG_CGROUPS vs CONFIG_CGROUP_PERF ?
Other than that, I see nothing wrong here.
next prev parent reply other threads:[~2020-01-07 12:51 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-23 6:07 [PATCHSET 0/9] perf: Improve cgroup profiling (v3) Namhyung Kim
2019-12-23 6:07 ` [PATCH 1/9] perf/core: Add PERF_RECORD_CGROUP event Namhyung Kim
2020-01-07 12:51 ` Peter Zijlstra [this message]
2020-01-07 13:46 ` Namhyung Kim
2019-12-23 6:07 ` [PATCH 2/9] perf/core: Add PERF_SAMPLE_CGROUP feature Namhyung Kim
2019-12-23 6:07 ` [PATCH 3/9] perf tools: Basic support for CGROUP event Namhyung Kim
2019-12-23 6:07 ` [PATCH 4/9] perf tools: Maintain cgroup hierarchy Namhyung Kim
2019-12-23 6:07 ` [PATCH 5/9] perf report: Add 'cgroup' sort key Namhyung Kim
2019-12-23 6:07 ` [PATCH 6/9] perf record: Support synthesizing cgroup events Namhyung Kim
2019-12-23 6:07 ` [PATCH 7/9] perf record: Add --all-cgroups option Namhyung Kim
2019-12-23 6:07 ` [PATCH 8/9] perf top: " Namhyung Kim
2019-12-23 6:07 ` [PATCH 9/9] perf script: Add --show-cgroup-events option Namhyung Kim
2019-12-23 17:35 ` [PATCHSET 0/9] perf: Improve cgroup profiling (v3) Vince Weaver
2019-12-24 0:40 ` Namhyung Kim
2019-12-26 12:46 ` Arnaldo Carvalho de Melo
2019-12-27 18:31 ` Vince Weaver
-- strict thread matches above, loose matches on Subject: below --
2020-03-25 12:45 [PATCHSET 0/9] perf: Improve cgroup profiling (v6) Namhyung Kim
2020-03-25 12:45 ` [PATCH 1/9] perf/core: Add PERF_RECORD_CGROUP event Namhyung Kim
2020-01-07 13:34 [PATCHSET 0/9] perf: Improve cgroup profiling (v4) Namhyung Kim
2020-01-07 13:34 ` [PATCH 1/9] perf/core: Add PERF_RECORD_CGROUP event Namhyung Kim
2019-12-20 4:32 [PATCHSET 0/9] perf: Improve cgroup profiling (v2) Namhyung Kim
2019-12-20 4:32 ` [PATCH 1/9] perf/core: Add PERF_RECORD_CGROUP event Namhyung Kim
2019-12-20 9:33 ` Peter Zijlstra
2019-12-20 11:28 ` Namhyung Kim
2019-12-20 11:50 ` Namhyung Kim
2019-12-20 15:16 ` Tejun Heo
2019-12-21 8:49 ` Namhyung Kim
2019-08-28 7:31 [PATCHSET 0/9] perf: Improve cgroup profiling (v1) Namhyung Kim
2019-08-28 7:31 ` [PATCH 1/9] perf/core: Add PERF_RECORD_CGROUP event Namhyung Kim
2019-08-28 9:44 ` Peter Zijlstra
2019-08-28 9:44 ` Peter Zijlstra
2019-08-28 13:13 ` Arnaldo Carvalho de Melo
2019-08-30 3:46 ` Namhyung Kim
2019-08-30 7:34 ` Peter Zijlstra
2019-08-30 22:49 ` Namhyung Kim
2019-08-30 23:52 ` Stephane Eranian
2019-08-28 14:48 ` Tejun Heo
2019-08-30 3:56 ` Namhyung Kim
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200107125131.GZ2844@hirez.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=acme@kernel.org \
--cc=adrian.hunter@intel.com \
--cc=alexander.shishkin@linux.intel.com \
--cc=eranian@google.com \
--cc=hannes@cmpxchg.org \
--cc=jolsa@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=lizefan@huawei.com \
--cc=mark.rutland@arm.com \
--cc=mingo@kernel.org \
--cc=namhyung@kernel.org \
--cc=tj@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).