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: <CAJZ5v0jvdttYihgNcTF=VVnd2K5QsC+W9XJJanqy4F_PXw+u2g@mail.gmail.com>
Date: Mon, 23 Jun 2025 17:30:44 +0200
From: "Rafael J. Wysocki" <rafael@...nel.org>
To: Lifeng Zheng <zhenglifeng1@...wei.com>
Cc: rafael@...nel.org, viresh.kumar@...aro.org, ionela.voinescu@....com, 
	linux-kernel@...r.kernel.org, linux-pm@...r.kernel.org, linuxarm@...wei.com, 
	jonathan.cameron@...wei.com, zhanjie9@...ilicon.com, lihuisong@...wei.com, 
	yubowen8@...wei.com
Subject: Re: [PATCH 3/7] cpufreq: Contain scaling_cur_freq.attr in cpufreq_attrs

On Mon, Jun 23, 2025 at 3:34 PM Lifeng Zheng <zhenglifeng1@...wei.com> wrote:
>
> After commit c034b02e213d ("cpufreq: expose scaling_cur_freq sysfs file for
> set_policy() drivers"), the file scaling_cur_freq is exposed to all
> drivers. No need to create this file separately. It's better to be
> contained in cpufreq_attrs.

Fair enough.

> Signed-off-by: Lifeng Zheng <zhenglifeng1@...wei.com>
> ---
>  drivers/cpufreq/cpufreq.c | 5 +----
>  1 file changed, 1 insertion(+), 4 deletions(-)
>
> diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
> index efc1f4ac85cb..2303890de0ba 100644
> --- a/drivers/cpufreq/cpufreq.c
> +++ b/drivers/cpufreq/cpufreq.c
> @@ -967,6 +967,7 @@ static struct attribute *cpufreq_attrs[] = {
>         &cpuinfo_min_freq.attr,
>         &cpuinfo_max_freq.attr,
>         &cpuinfo_transition_latency.attr,
> +       &scaling_cur_freq.attr,
>         &scaling_min_freq.attr,
>         &scaling_max_freq.attr,
>         &affected_cpus.attr,
> @@ -1095,10 +1096,6 @@ static int cpufreq_add_dev_interface(struct cpufreq_policy *policy)
>                         return ret;
>         }
>
> -       ret = sysfs_create_file(&policy->kobj, &scaling_cur_freq.attr);
> -       if (ret)
> -               return ret;
> -
>         if (cpufreq_driver->bios_limit) {
>                 ret = sysfs_create_file(&policy->kobj, &bios_limit.attr);
>                 if (ret)
> --
> 2.33.0
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ