lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZmvDl80DQRvtOkoh@chenyu5-mobl2>
Date: Fri, 14 Jun 2024 12:14:15 +0800
From: Chen Yu <yu.c.chen@...el.com>
To: K Prateek Nayak <kprateek.nayak@....com>
CC: Chunxin Zang <spring.cxz@...il.com>, Honglei Wang
	<jameshongleiwang@....com>, <mingo@...hat.com>, Peter Zijlstra
	<peterz@...radead.org>, <juri.lelli@...hat.com>,
	<vincent.guittot@...aro.org>, <dietmar.eggemann@....com>,
	<rostedt@...dmis.org>, <bsegall@...gle.com>, <mgorman@...e.de>,
	<bristot@...hat.com>, <vschneid@...hat.com>, Mike Galbraith <efault@....de>,
	<linux-kernel@...r.kernel.org>, <yangchen11@...iang.com>, Jerry Zhou
	<zhouchunhua@...iang.com>, Chunxin Zang <zangchunxin@...iang.com>
Subject: Re: [PATCH v2] sched/fair: Reschedule the cfs_rq when current is
 ineligible

Hi Prateek,

On 2024-06-14 at 08:46:54 +0530, K Prateek Nayak wrote:
> Hello Chenyu,
> 
> > > +static bool check_curr_preempt(struct cfs_rq *cfs_rq, struct
> > > sched_entity *curr)
> > > +{
> > > +    if (sched_feat(RUN_TO_PARITY) || cfs_rq->nr_running <= 1 ||
> > > +        !entity_eligible(cfs_rq, curr))
> > 
> > Shouldn't this return false if "entity_eligible(cfs_rq, curr)" returns
> > true since curr is still vruntime eligible on cfs_rq?
> > 
> > Would it better to have check_curr_preempt() as follows:
> > 
> >      if (sched_feat(RUN_TO_PARITY) || cfs_rq->nr_running <= 1)
> >          return false;
> > 
> >      return entity_eligible(cfs_rq, curr);
> 
> The above return should have been:
> 
> 	return !entity_eligible(cfs_rq, curr);
> 
> Which returns true once curr is not vruntime eligible on cfs_rq.
> Sorry for the oversight.
>

Yes, you are right, thanks for catching this.

thanks,
Chenyu 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ