linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephane Eranian <eranian@google.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: LKML <linux-kernel@vger.kernel.org>, Jiri Olsa <jolsa@redhat.com>,
	"mingo@elte.hu" <mingo@elte.hu>
Subject: Re: perf: question about event scheduler
Date: Mon, 29 Jul 2013 11:23:46 +0200	[thread overview]
Message-ID: <CABPqkBTeQeR3n_KDWffWmz0AxL8+ynfvv0tCSjPP8aCh81dgPg@mail.gmail.com> (raw)
In-Reply-To: <20130723094832.GV27075@twins.programming.kicks-ass.net>

On Tue, Jul 23, 2013 at 11:48 AM, Peter Zijlstra <peterz@infradead.org> wrote:
>
> On Tue, Jul 23, 2013 at 10:13:33AM +0200, Stephane Eranian wrote:
> > Hi,
> >
> > I am looking at ctx_pinned_sched_in() and
> > ctx_flexible_sched_in() and I am trying to
> > understand the difference of treatment in
> > case of errors for the two classes of events
> > (pinned vs. flexible).
> >
> > For pinned events, when a group fails to
> > schedule in, the code goes on to the next
> > group and therefore walks the entire list
> > for each scheduler invocation.
> >
> > For flexible events, when a group fails,
> > the loop aborts and no subsequent group
> > is tried.
> >
> > I am trying to understand the motivation for
> > this difference here.
> >
> > If I recall, the abort is here to limit malicious
> > DoS where a malicious user would provide
> > an arbitrary long list of events, hogging the kernel.
> > But in the case of pinned events, this is ignored
> > because to create such events one needs to be
> > root in the first place.
> >
> > Am I getting this right?
>
> Whee, long time ago. I think the biggest reason is that pinned events
> should always be scheduled. Not being able to schedule a pinned event is
> an error. But yes, that and the fact that they're root only.
>
>
Ok, that's what I thought then.
Thanks,

      reply	other threads:[~2013-07-29  9:23 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-23  8:13 perf: question about event scheduler Stephane Eranian
2013-07-23  9:48 ` Peter Zijlstra
2013-07-29  9:23   ` Stephane Eranian [this message]

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=CABPqkBTeQeR3n_KDWffWmz0AxL8+ynfvv0tCSjPP8aCh81dgPg@mail.gmail.com \
    --to=eranian@google.com \
    --cc=jolsa@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=peterz@infradead.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).