public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Peter Williams <pwil3058@bigpond.net.au>
To: Jarek Poplawski <jarkao2@o2.pl>
Cc: Dmitry Adamushko <dmitry.adamushko@gmail.com>,
	Ingo Molnar <mingo@elte.hu>, Nick Piggin <npiggin@suse.de>,
	"Siddha\, Suresh B" <suresh.b.siddha@intel.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] sched: Rationalize sys_sched_rr_get_interval()
Date: Sat, 13 Oct 2007 11:29:33 +1000	[thread overview]
Message-ID: <47101F7D.8050101@bigpond.net.au> (raw)
In-Reply-To: <20071012064927.GA1962@ff.dom.local>

Jarek Poplawski wrote:
> On 12-10-2007 00:23, Peter Williams wrote:
> ...
>> The reason I was going that route was for modularity (which helps when 
>> adding plugsched patches).  I'll submit a revised patch for consideration.
> ...
> 
> IMHO, it looks like modularity could suck here:
> 
>> +static unsigned int default_timeslice_fair(struct task_struct *p)
>> +{
>> +	return NS_TO_JIFFIES(sysctl_sched_min_granularity);
>> +}
> 
> If it's needed for outside and sched_fair will use something else
> (to avoid double conversion) this could be misleading. Shouldn't
> this be kind of private and return something usable for the class
> mainly?

This is supplying data for a system call not something for internal use 
by the class.  As far as the sched_fair class is concerned this is just 
a (necessary - because it's need by a system call) diversion.

> Why anything else than sched_fair should care about this?

sched_fair doesn't care so if nothing else does why do we even have 
sys_sched_rr_get_interval()?  Is this whole function an anachronism that 
can be expunged?  I'm assuming that the reason it exists is that there 
are user space programs that use this system call.  Am I correct in this 
assumption?  Personally, I can't think of anything it would be useful 
for other than satisfying curiosity.

Peter
-- 
Peter Williams                                   pwil3058@bigpond.net.au

"Learning, n. The kind of ignorance distinguishing the studious."
  -- Ambrose Bierce

  reply	other threads:[~2007-10-13  5:00 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-11  0:37 [PATCH] sched: Rationalize sys_sched_rr_get_interval() Peter Williams
2007-10-11  6:59 ` Ingo Molnar
2007-10-11  7:44   ` Dmitry Adamushko
2007-10-11 22:23     ` Peter Williams
2007-10-12  6:49       ` Jarek Poplawski
2007-10-13  1:29         ` Peter Williams [this message]
2007-10-15 11:11           ` Jarek Poplawski
2007-10-16  1:16             ` Peter Williams
2007-10-16  9:42               ` Jarek Poplawski
2007-10-17  0:23                 ` Peter Williams
2007-10-12  6:59       ` Ingo Molnar

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=47101F7D.8050101@bigpond.net.au \
    --to=pwil3058@bigpond.net.au \
    --cc=dmitry.adamushko@gmail.com \
    --cc=jarkao2@o2.pl \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=npiggin@suse.de \
    --cc=suresh.b.siddha@intel.com \
    /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