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] [thread-next>] [day] [month] [year] [list]
Message-ID: <20101014053947.GB4378@balbir.in.ibm.com>
Date:	Thu, 14 Oct 2010 11:09:47 +0530
From:	Balbir Singh <balbir@...ux.vnet.ibm.com>
To:	Nikhil Rao <ncrao@...gle.com>
Cc:	Bharata B Rao <bharata@...ux.vnet.ibm.com>,
	linux-kernel@...r.kernel.org,
	Dhaval Giani <dhaval.giani@...il.com>,
	Vaidyanathan Srinivasan <svaidy@...ux.vnet.ibm.com>,
	Srivatsa Vaddagiri <vatsa@...ibm.com>,
	Kamalesh Babulal <kamalesh@...ux.vnet.ibm.com>,
	Ingo Molnar <mingo@...e.hu>,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>,
	Pavel Emelyanov <xemul@...nvz.org>,
	Herbert Poetzl <herbert@...hfloor.at>,
	Avi Kivity <avi@...hat.com>,
	Chris Friesen <cfriesen@...tel.com>,
	Paul Menage <menage@...gle.com>,
	Mike Waychison <mikew@...gle.com>, Paul Turner <pjt@...gle.com>
Subject: Re: [PATCH v3 2/7] sched: accumulate per-cfs_rq cpu usage

* Nikhil Rao <ncrao@...gle.com> [2010-10-13 07:41:46]:

> On Wed, Oct 13, 2010 at 6:59 AM, Balbir Singh <balbir@...ux.vnet.ibm.com> wrote:
> > * Nikhil Rao <ncrao@...gle.com> [2010-10-13 06:46:18]:
> >
> >> > Quick question for cfs_b->quota == RUNTIME_INF, won't cfs_b->runtime
> >> > be always > 0?
> >>
> >> Hi Balbir,
> >>
> >> cfs_b->runtime can be 0 if the task group exhausts its quota.
> >> cfs_b->runtime is a counter that is periodically refreshed to
> >> cfs_b->quota, and is decremented every time a cfs_rq requests a slice.
> >>
> >
> > Thanks, Nikhil
> >
> > I saw several checks for quota == RUNTIME_INF and saw updates not
> > happening. Do we track usage for cgroups with infinite quota? IOW, is
> > runtime updated? If so, why?
> >
> 
> We don't track usage or update runtime for cgroups with infinite
> quota. Most of these RUNTIME_INF checks are usually at the top of the
> functions and return immediately. The checks in the middle of
> functions are mostly to prevent races when cfs_b->quota is updated.
> 
> And ... I think I might have misunderstood your original question. Let
> me try answering that again. We check for quota == RUNTIME_INF (in
> addition to cfs_b->runtime > 0) because it is possible that the global
> pool is updated to RUNTIME_INF between the quota check in
> account_cfs_rq_quota() and when the actual quota is distributed in
> tg_request_cfs_quota(). I hope that answers your original question.
>

Yes, it does, thanks! 

-- 
	Three Cheers,
	Balbir
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ