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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <495d461a-d643-5dbf-7da8-74ddbdc486ca@arm.com>
Date:   Tue, 26 Oct 2021 18:51:18 +0200
From:   Dietmar Eggemann <dietmar.eggemann@....com>
To:     Lukasz Luba <lukasz.luba@....com>, linux-kernel@...r.kernel.org,
        linux-pm@...r.kernel.org
Cc:     linux-arm-kernel@...ts.infradead.org,
        linux-arm-msm@...r.kernel.org, sudeep.holla@....com,
        will@...nel.org, catalin.marinas@....com, linux@...linux.org.uk,
        gregkh@...uxfoundation.org, rafael@...nel.org,
        viresh.kumar@...aro.org, amitk@...nel.org,
        daniel.lezcano@...aro.org, amit.kachhap@...il.com,
        thara.gopinath@...aro.org, bjorn.andersson@...aro.org,
        agross@...nel.org
Subject: Re: [PATCH v2 2/5] thermal: cpufreq_cooling: Use new thermal pressure
 update function

On 15/10/2021 16:45, Lukasz Luba wrote:

[...]

> @@ -479,10 +478,7 @@ static int cpufreq_set_cur_state(struct thermal_cooling_device *cdev,
>  	if (ret >= 0) {
>  		cpufreq_cdev->cpufreq_state = state;
>  		cpus = cpufreq_cdev->policy->related_cpus;
> -		max_capacity = arch_scale_cpu_capacity(cpumask_first(cpus));
> -		capacity = frequency * max_capacity;
> -		capacity /= cpufreq_cdev->policy->cpuinfo.max_freq;

Took me a while to realize that `cpufreq_cdev->policy->cpuinfo.max_freq`
is 1000 * per_cpu(freq_factor, cpu), the latter being used now in
arch_thermal_pressure_update(). Maybe worth mentioning in the patch header?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ