Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1257495

Re: [PATCH v2] perf/core: fix RCU issues with cgroup monitoring mode

From Eric Dumazet <eric.dumazet@gmail.com>
Newsgroups linux.kernel
Subject Re: [PATCH v2] perf/core: fix RCU issues with cgroup monitoring mode
Date 2015-10-28 01:20 +0100
Message-ID <qomD8-3DG-19@gated-at.bofh.it> (permalink)
References <qoi6v-J0-39@gated-at.bofh.it> <qoj2y-1i5-27@gated-at.bofh.it> <qoma5-3eI-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tue, 2015-10-27 at 16:37 -0700, Stephane Eranian wrote:

> But that macro is already embedded into the  task_css_set() macro.
> What we are saying here is that we have another way of ensuring the
> cgroup cannot disappear here, and thus the rcu lockdep detects we
> are not holding the rcu read lock but we know this is okay. We are
> trying to avoid grabbing the rcu read lock when it is not really needed
> to guarantee correct execution. So we are just shutting up the lockdep
> in these particular cases by passing true as the safe argument value.

Sure, but in lockdep verbs, the following :

+       /* holding ctx->lock, so cgroup access is safe */
+       cgrp = perf_cgroup_from_task(task, true);

would map to :

cgrp = perf_cgroup_from_task(task, lockdep_is_held(&ctx->lock));

Notice the comment becomes useless.



--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v2] perf/core: fix RCU issues with cgroup monitoring mode Stephane Eranian <eranian@google.com> - 2015-10-27 20:30 +0100
  Re: [PATCH v2] perf/core: fix RCU issues with cgroup monitoring mode Eric Dumazet <eric.dumazet@gmail.com> - 2015-10-27 21:30 +0100
    Re: [PATCH v2] perf/core: fix RCU issues with cgroup monitoring mode Stephane Eranian <eranian@google.com> - 2015-10-28 00:50 +0100
      Re: [PATCH v2] perf/core: fix RCU issues with cgroup monitoring mode Eric Dumazet <eric.dumazet@gmail.com> - 2015-10-28 01:20 +0100
        Re: [PATCH v2] perf/core: fix RCU issues with cgroup monitoring mode Stephane Eranian <eranian@google.com> - 2015-10-28 01:30 +0100
    Re: [PATCH v2] perf/core: fix RCU issues with cgroup monitoring mode Peter Zijlstra <peterz@infradead.org> - 2015-10-28 01:20 +0100

csiph-web