[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20200911090632.GC1362448@hirez.programming.kicks-ass.net>
Date: Fri, 11 Sep 2020 11:06:32 +0200
From: peterz@...radead.org
To: qianjun.kernel@...il.com
Cc: mingo@...hat.com, juri.lelli@...hat.com,
vincent.guittot@...aro.org, linux-kernel@...r.kernel.org,
laoar.shao@...il.com
Subject: Re: [PATCH 1/1] kernel/sched:use the enum code replace of the int
variable
On Mon, Sep 07, 2020 at 09:05:02PM +0800, qianjun.kernel@...il.com wrote:
> From: jun qian <qianjun.kernel@...il.com>
>
> It is hard to understand what the meaning of the value from
> the return value of wakeup_preempt_entity, so I fix it.
> @@ -6822,9 +6828,9 @@ static unsigned long wakeup_gran(struct sched_entity *se)
> * g
> * |<--->|c
> *
> - * w(c, s1) = -1
> - * w(c, s2) = 0
> - * w(c, s3) = 1
> + * w(c, s1) = NO_NEED_PREEMPT
> + * w(c, s2) = MAY_NEED_PREEMPT
> + * w(c, s3) = NEED_PREEMPT
> *
> */
Yeah, I don't think so. The function is a simple C style compare,
where negative is less, 0 is equal and positive is more than.
Powered by blists - more mailing lists