Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1599189 > unrolled thread

Re: [RFC v3 1/5] sched/core: add capacity constraints to CPU controller

Started by"Joel Fernandes (Google)" <joel.opensrc@gmail.com>
First post2017-03-13 11:50 +0100
Last post2017-03-13 11:50 +0100
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [RFC v3 1/5] sched/core: add capacity constraints to CPU controller "Joel Fernandes (Google)" <joel.opensrc@gmail.com> - 2017-03-13 11:50 +0100

#1599189 — Re: [RFC v3 1/5] sched/core: add capacity constraints to CPU controller

From"Joel Fernandes (Google)" <joel.opensrc@gmail.com>
Date2017-03-13 11:50 +0100
SubjectRe: [RFC v3 1/5] sched/core: add capacity constraints to CPU controller
Message-ID<tkvI5-7IV-1@gated-at.bofh.it>
On Tue, Feb 28, 2017 at 6:38 AM, Patrick Bellasi
<patrick.bellasi@arm.com> wrote:
> The CPU CGroup controller allows to assign a specified (maximum)
> bandwidth to tasks within a group, however it does not enforce any
> constraint on how such bandwidth can be consumed.
> With the integration of schedutil, the scheduler has now the proper
> information about a task to select  the most suitable frequency to
> satisfy tasks needs.
[..]

> +static u64 cpu_capacity_min_read_u64(struct cgroup_subsys_state *css,
> +                                    struct cftype *cft)
> +{
> +       struct task_group *tg;
> +       u64 min_capacity;
> +
> +       rcu_read_lock();
> +       tg = css_tg(css);
> +       min_capacity = tg->cap_clamp[CAP_CLAMP_MIN];

Shouldn't the cap_clamp be accessed with READ_ONCE (and WRITE_ONCE in
the write path) to avoid load-tearing?

Thanks,
Joel

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web