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: <20220307054432.amawi7afl3vudfjn@vireshk-i7>
Date:   Mon, 7 Mar 2022 11:14:32 +0530
From:   Viresh Kumar <viresh.kumar@...aro.org>
To:     zhanglianjie <zhanglianjie@...ontech.com>
Cc:     "Rafael J. Wysocki" <rafael@...nel.org>, linux-pm@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] cpufreq: use helper macro __ATTR_XX

On 06-03-22, 10:12, zhanglianjie wrote:
> Use helper macro __ATTR_XX  to make code more clear.
> Minor readability improvement.
> 
> Signed-off-by: zhanglianjie <zhanglianjie@...ontech.com>
> 
> diff --git a/drivers/cpufreq/cpufreq_governor.h b/drivers/cpufreq/cpufreq_governor.h
> index 65ecf32ba4f8..a5a0bc3cc23e 100644
> --- a/drivers/cpufreq/cpufreq_governor.h
> +++ b/drivers/cpufreq/cpufreq_governor.h
> @@ -68,12 +68,10 @@ static ssize_t file_name##_show						\
>  }
> 
>  #define gov_attr_ro(_name)						\
> -static struct governor_attr _name =					\
> -__ATTR(_name, 0444, _name##_show, NULL)
> +static struct governor_attr _name = __ATTR_RO(_name)
> 
>  #define gov_attr_rw(_name)						\
> -static struct governor_attr _name =					\
> -__ATTR(_name, 0644, _name##_show, _name##_store)
> +static struct governor_attr _name = __ATTR_RW(_name)
> 
>  /* Common to all CPUs of a policy */
>  struct policy_dbs_info {

This change looks fine though.

-- 
viresh

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ