mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] cpufreq: powernow-k6: replace symbolic permissions with octal
@ 2026-06-12 23:16 Jack Lee
  2026-06-13 15:00 ` Zhongqiu Han
  0 siblings, 1 reply; 5+ messages in thread
From: Jack Lee @ 2026-06-12 23:16 UTC (permalink / raw)
  To: rafael, viresh.kumar; +Cc: linux-pm, linux-kernel, Jack Lee

Symbolic permissions S_IRUGO are deprecated in favor of octal
permissions. Replace S_IRUGO with 0444.

Signed-off-by: Jack Lee <skunkolee@gmail.com>
---
 drivers/cpufreq/powernow-k6.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/cpufreq/powernow-k6.c b/drivers/cpufreq/powernow-k6.c
index 99d2244e03b0..764907b04c04 100644
--- a/drivers/cpufreq/powernow-k6.c
+++ b/drivers/cpufreq/powernow-k6.c
@@ -29,10 +29,10 @@ static unsigned int                     max_multiplier;
 static unsigned int			param_busfreq = 0;
 static unsigned int			param_max_multiplier = 0;
 
-module_param_named(max_multiplier, param_max_multiplier, uint, S_IRUGO);
+module_param_named(max_multiplier, param_max_multiplier, uint, 0444);
 MODULE_PARM_DESC(max_multiplier, "Maximum multiplier (allowed values: 20 30 35 40 45 50 55 60)");
 
-module_param_named(bus_frequency, param_busfreq, uint, S_IRUGO);
+module_param_named(bus_frequency, param_busfreq, uint, 0444);
 MODULE_PARM_DESC(bus_frequency, "Bus frequency in kHz");
 
 /* Clock ratio multiplied by 10 - see table 27 in AMD#23446 */
-- 
2.54.0


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] cpufreq: powernow-k6: replace symbolic permissions with octal
  2026-06-12 23:16 [PATCH] cpufreq: powernow-k6: replace symbolic permissions with octal Jack Lee
@ 2026-06-13 15:00 ` Zhongqiu Han
  2026-06-13 17:15   ` Jack Lee
  0 siblings, 1 reply; 5+ messages in thread
From: Zhongqiu Han @ 2026-06-13 15:00 UTC (permalink / raw)
  To: Jack Lee, rafael, viresh.kumar; +Cc: linux-pm, linux-kernel, zhongqiu.han

On 6/13/2026 7:16 AM, Jack Lee wrote:
> Symbolic permissions S_IRUGO are deprecated in favor of octal
> permissions. Replace S_IRUGO with 0444.


Hi Jack,

Thanks for the patch, the change itself looks reasonable.

However, I'm not sure whether this cleanup alone is compelling enough
for merge.

It might be worth clarifying the commit message, though — as far as I
know, S_IRUGO is not formally deprecated, but rather not preferred,
with octal permissions generally recommended instead (see
Documentation/dev-tools/checkpatch.rst[1]). Using wording closer to
that might be more precise.

[1] 
https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git/tree/Documentation/dev-tools/checkpatch.rst#n1060


> 
> Signed-off-by: Jack Lee <skunkolee@gmail.com>
> ---
>   drivers/cpufreq/powernow-k6.c | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/cpufreq/powernow-k6.c b/drivers/cpufreq/powernow-k6.c
> index 99d2244e03b0..764907b04c04 100644
> --- a/drivers/cpufreq/powernow-k6.c
> +++ b/drivers/cpufreq/powernow-k6.c
> @@ -29,10 +29,10 @@ static unsigned int                     max_multiplier;
>   static unsigned int			param_busfreq = 0;
>   static unsigned int			param_max_multiplier = 0;
>   
> -module_param_named(max_multiplier, param_max_multiplier, uint, S_IRUGO);
> +module_param_named(max_multiplier, param_max_multiplier, uint, 0444);
>   MODULE_PARM_DESC(max_multiplier, "Maximum multiplier (allowed values: 20 30 35 40 45 50 55 60)");
>   
> -module_param_named(bus_frequency, param_busfreq, uint, S_IRUGO);
> +module_param_named(bus_frequency, param_busfreq, uint, 0444);
>   MODULE_PARM_DESC(bus_frequency, "Bus frequency in kHz");
>   
>   /* Clock ratio multiplied by 10 - see table 27 in AMD#23446 */


-- 
Thx and BRs,
Zhongqiu Han

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH] cpufreq: powernow-k6: replace symbolic permissions with octal
  2026-06-13 15:00 ` Zhongqiu Han
@ 2026-06-13 17:15   ` Jack Lee
  2026-06-15  4:53     ` Viresh Kumar
  2026-06-23 13:13     ` Rafael J. Wysocki
  0 siblings, 2 replies; 5+ messages in thread
From: Jack Lee @ 2026-06-13 17:15 UTC (permalink / raw)
  To: rafael, viresh.kumar; +Cc: linux-pm, linux-kernel, zhongqiu.han, Jack Lee

Symbolic permissions S_IRUGO are not preferred. Replace with octal
permissions 0444 as recommended by checkpatch.

Signed-off-by: Jack Lee <skunkolee@gmail.com>
---
 drivers/cpufreq/powernow-k6.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/cpufreq/powernow-k6.c b/drivers/cpufreq/powernow-k6.c
index 99d2244e03b0..764907b04c04 100644
--- a/drivers/cpufreq/powernow-k6.c
+++ b/drivers/cpufreq/powernow-k6.c
@@ -29,10 +29,10 @@ static unsigned int                     max_multiplier;
 static unsigned int			param_busfreq = 0;
 static unsigned int			param_max_multiplier = 0;
 
-module_param_named(max_multiplier, param_max_multiplier, uint, S_IRUGO);
+module_param_named(max_multiplier, param_max_multiplier, uint, 0444);
 MODULE_PARM_DESC(max_multiplier, "Maximum multiplier (allowed values: 20 30 35 40 45 50 55 60)");
 
-module_param_named(bus_frequency, param_busfreq, uint, S_IRUGO);
+module_param_named(bus_frequency, param_busfreq, uint, 0444);
 MODULE_PARM_DESC(bus_frequency, "Bus frequency in kHz");
 
 /* Clock ratio multiplied by 10 - see table 27 in AMD#23446 */
-- 
2.54.0


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] cpufreq: powernow-k6: replace symbolic permissions with octal
  2026-06-13 17:15   ` Jack Lee
@ 2026-06-15  4:53     ` Viresh Kumar
  2026-06-23 13:13     ` Rafael J. Wysocki
  1 sibling, 0 replies; 5+ messages in thread
From: Viresh Kumar @ 2026-06-15  4:53 UTC (permalink / raw)
  To: Jack Lee; +Cc: rafael, linux-pm, linux-kernel, zhongqiu.han

On 13-06-26, 11:15, Jack Lee wrote:
> Symbolic permissions S_IRUGO are not preferred. Replace with octal
> permissions 0444 as recommended by checkpatch.
> 
> Signed-off-by: Jack Lee <skunkolee@gmail.com>
> ---
>  drivers/cpufreq/powernow-k6.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/cpufreq/powernow-k6.c b/drivers/cpufreq/powernow-k6.c
> index 99d2244e03b0..764907b04c04 100644
> --- a/drivers/cpufreq/powernow-k6.c
> +++ b/drivers/cpufreq/powernow-k6.c
> @@ -29,10 +29,10 @@ static unsigned int                     max_multiplier;
>  static unsigned int			param_busfreq = 0;
>  static unsigned int			param_max_multiplier = 0;
>  
> -module_param_named(max_multiplier, param_max_multiplier, uint, S_IRUGO);
> +module_param_named(max_multiplier, param_max_multiplier, uint, 0444);
>  MODULE_PARM_DESC(max_multiplier, "Maximum multiplier (allowed values: 20 30 35 40 45 50 55 60)");
>  
> -module_param_named(bus_frequency, param_busfreq, uint, S_IRUGO);
> +module_param_named(bus_frequency, param_busfreq, uint, 0444);
>  MODULE_PARM_DESC(bus_frequency, "Bus frequency in kHz");
>  
>  /* Clock ratio multiplied by 10 - see table 27 in AMD#23446 */

Acked-by: Viresh Kumar <viresh.kumar@linaro.org>

-- 
viresh

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] cpufreq: powernow-k6: replace symbolic permissions with octal
  2026-06-13 17:15   ` Jack Lee
  2026-06-15  4:53     ` Viresh Kumar
@ 2026-06-23 13:13     ` Rafael J. Wysocki
  1 sibling, 0 replies; 5+ messages in thread
From: Rafael J. Wysocki @ 2026-06-23 13:13 UTC (permalink / raw)
  To: Jack Lee; +Cc: rafael, viresh.kumar, linux-pm, linux-kernel, zhongqiu.han

On Sat, Jun 13, 2026 at 7:16 PM Jack Lee <skunkolee@gmail.com> wrote:
>
> Symbolic permissions S_IRUGO are not preferred. Replace with octal
> permissions 0444 as recommended by checkpatch.
>
> Signed-off-by: Jack Lee <skunkolee@gmail.com>

I don't see a good enough reason for making this change, sorry.

First, checkpatch.pl messages regarding the existing code are irrelevant.

Second, this particular driver is in a deep maintenance mode and the
particular update in question is not significant enough for touching
it IMV.

> ---
>  drivers/cpufreq/powernow-k6.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/cpufreq/powernow-k6.c b/drivers/cpufreq/powernow-k6.c
> index 99d2244e03b0..764907b04c04 100644
> --- a/drivers/cpufreq/powernow-k6.c
> +++ b/drivers/cpufreq/powernow-k6.c
> @@ -29,10 +29,10 @@ static unsigned int                     max_multiplier;
>  static unsigned int                    param_busfreq = 0;
>  static unsigned int                    param_max_multiplier = 0;
>
> -module_param_named(max_multiplier, param_max_multiplier, uint, S_IRUGO);
> +module_param_named(max_multiplier, param_max_multiplier, uint, 0444);
>  MODULE_PARM_DESC(max_multiplier, "Maximum multiplier (allowed values: 20 30 35 40 45 50 55 60)");
>
> -module_param_named(bus_frequency, param_busfreq, uint, S_IRUGO);
> +module_param_named(bus_frequency, param_busfreq, uint, 0444);
>  MODULE_PARM_DESC(bus_frequency, "Bus frequency in kHz");
>
>  /* Clock ratio multiplied by 10 - see table 27 in AMD#23446 */
> --
> 2.54.0
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-06-23 13:13 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-06-12 23:16 [PATCH] cpufreq: powernow-k6: replace symbolic permissions with octal Jack Lee
2026-06-13 15:00 ` Zhongqiu Han
2026-06-13 17:15   ` Jack Lee
2026-06-15  4:53     ` Viresh Kumar
2026-06-23 13:13     ` Rafael J. Wysocki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome