Re: [PATCH] O10int for interactivity

From: Con Kolivas (kernel@kolivas.org)
Date: Tue Jul 29 2003 - 20:36:06 EST


On Wed, 30 Jul 2003 11:16, Diego Calleja García wrote:
> El Wed, 30 Jul 2003 00:35:01 +1000 Con Kolivas <kernel@kolivas.org>
escribió:
> > That's not as silly as it sounds. In fact it should be dead easy to
> > increase/decrease the amount of anticipatory time based on the bonus from
> > looking at the code. I dunno how the higher filesystem gods feel about
> > this though.
>
> I've done a small patch (one line) which tries to implement that.
> At as-iosched.c:as_add_request() there's:

The logic is in the difference between the dynamic and the static priority to
determine if a task is interactive.
current->static_prio - current->prio
will give you a number of -5 to +5, with +5 being a good bonus and vice versa.
however you need to ensure that the value you are fiddling with in the i/o
scheduler is actually due to the current process[1]

On top of that, the p->prio itself will give you a number of 0-140 depending
with higher being a lower priority task; numbers 100-140 are for user tasks
and <100 for real time tasks.

These all change if you fiddle with the magic in bonus ratios and max rt prio
etc.

Con

[1] This is why I didn't bother posting my attempts ;)

-
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/



This archive was generated by hypermail 2b29 : Thu Jul 31 2003 - 22:00:43 EST