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]
Date:   Tue, 16 Aug 2022 13:24:13 +0800
From:   Tianchen Ding <dtcccc@...ux.alibaba.com>
To:     Zhao Wenhui <zhaowenhui8@...wei.com>
Cc:     zhaogongyi@...wei.com, mingo@...hat.com, 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,
        shanpeic@...ux.alibaba.com, changhuaixin@...ux.alibaba.com,
        tj@...nel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] sched/fair: limit burst to zero when cfs bandwidth is
 toggled off

On 2022/8/9 20:03, Zhao Wenhui wrote:
> When the quota value in CFS bandwidth is set to -1, that imples the
> cfs bandwidth is toggled off. So the burst feature is supposed to
> be disable as well.
> 
> Currently, when quota is -1, burst will not be check, so that it can be
> set to almost arbitery value. Examples:
>          mkdir /sys/fs/cgroup/cpu/test
>          echo -1 > /sys/fs/cgroup/cpu/test/cpu.cfs_quota_us
>          echo 10000000000000000 > /sys/fs/cgroup/cpu/test/cpu.cfs_burst_us
> 
> Moreover, after the burst modified by this way, quota can't be set
> to any value:
>          echo 100000 > cpu.cfs_quota_us
>          -bash: echo: write error: Invalid argument
> 
> This patch can ensure the burst value being zero and unalterable,
> when quota is set to -1.
> 
> Fixes: f4183717b370 ("sched/fair: Introduce the burstable CFS controller")
> Reported-by: Zhao Gongyi <zhaogongyi@...wei.com>
> Signed-off-by: Zhao Wenhui <zhaowenhui8@...wei.com>

Nice catch! Thanks for the fix.
Reviewed-by: Tianchen Ding <dtcccc@...ux.alibaba.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ