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  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:   Mon, 4 Mar 2019 13:58:12 +0000
From:   Quentin Perret <>
To:     Wang, Vincent (王争) 
Cc:     Zhang, Chunyan (张春艳) 
        <>, Ingo Molnar <>,
        Peter Zijlstra <>,
        "" <>,
        Chunyan Zhang <>
Subject: Re: 答复: [PATCH V4] sched/cpufreq: initialize iowait_boost_max and
 iowait_boost with cpu capacity

On Monday 04 Mar 2019 at 07:35:04 (+0000), Wang, Vincent (王争) wrote:
> Did you mean the value of arch_scale_cpu_capacity() is changed in
> cpu_capacity_store()?

Yes, there's that, but more importantly topology_normalize_cpu_scale()
is called during boot. With printks() in the relevant functions, the
boot log on my system with two CPUFreq policies looks like this:

[    2.393085] init_cpu_capacity_callback: policy0
[    2.397714] sugov_start: policy0
[    2.403734] init_cpu_capacity_callback: policy1
[    2.407901] topology_normalize_cpu_scale: done
[    2.412581] sugov_start: policy1

So, the lack of order of sugov_start() and topology_normalize_cpu_scale()
is a problem, I think.

> If so, I can restart schedutil governor after new capacity is updated.

Hmm, that feels a bit overkill, but that should at least be a correct
way of updating sg_cpu->{min, max} in a non-racy way. And CPU capacity
changes are infrequent, so the overhead of re-starting the governor
isn't a major issue, I suppose.

You could also update the values in sugov_get_util() at the cost of a
small overhead to compute 'min'. I'm not sure what's preferable since
we wanted to avoid that kind of overhead in the first place ...


Powered by blists - more mailing lists