* [PATCH v1 1/1] cpufreq: ACPI: Use str_enabled_disabled() helper
@ 2022-10-08 19:52 Andy Shevchenko
2022-11-03 18:12 ` Rafael J. Wysocki
0 siblings, 1 reply; 2+ messages in thread
From: Andy Shevchenko @ 2022-10-08 19:52 UTC (permalink / raw)
To: Andy Shevchenko, linux-pm, linux-kernel; +Cc: Rafael J. Wysocki, Viresh Kumar
Use str_enabled_disabled() helper instead of open coding the same.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
drivers/cpufreq/acpi-cpufreq.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/cpufreq/acpi-cpufreq.c b/drivers/cpufreq/acpi-cpufreq.c
index 1bb2b90ebb21..8597ab0a84b5 100644
--- a/drivers/cpufreq/acpi-cpufreq.c
+++ b/drivers/cpufreq/acpi-cpufreq.c
@@ -19,6 +19,7 @@
#include <linux/compiler.h>
#include <linux/dmi.h>
#include <linux/slab.h>
+#include <linux/string_helpers.h>
#include <linux/acpi.h>
#include <linux/io.h>
@@ -135,8 +136,8 @@ static int set_boost(struct cpufreq_policy *policy, int val)
{
on_each_cpu_mask(policy->cpus, boost_set_msr_each,
(void *)(long)val, 1);
- pr_debug("CPU %*pbl: Core Boosting %sabled.\n",
- cpumask_pr_args(policy->cpus), val ? "en" : "dis");
+ pr_debug("CPU %*pbl: Core Boosting %s.\n",
+ cpumask_pr_args(policy->cpus), str_enabled_disabled(val));
return 0;
}
--
2.35.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v1 1/1] cpufreq: ACPI: Use str_enabled_disabled() helper
2022-10-08 19:52 [PATCH v1 1/1] cpufreq: ACPI: Use str_enabled_disabled() helper Andy Shevchenko
@ 2022-11-03 18:12 ` Rafael J. Wysocki
0 siblings, 0 replies; 2+ messages in thread
From: Rafael J. Wysocki @ 2022-11-03 18:12 UTC (permalink / raw)
To: Andy Shevchenko; +Cc: linux-pm, linux-kernel, Rafael J. Wysocki, Viresh Kumar
On Sat, Oct 8, 2022 at 9:52 PM Andy Shevchenko
<andriy.shevchenko@linux.intel.com> wrote:
>
> Use str_enabled_disabled() helper instead of open coding the same.
>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> ---
> drivers/cpufreq/acpi-cpufreq.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/cpufreq/acpi-cpufreq.c b/drivers/cpufreq/acpi-cpufreq.c
> index 1bb2b90ebb21..8597ab0a84b5 100644
> --- a/drivers/cpufreq/acpi-cpufreq.c
> +++ b/drivers/cpufreq/acpi-cpufreq.c
> @@ -19,6 +19,7 @@
> #include <linux/compiler.h>
> #include <linux/dmi.h>
> #include <linux/slab.h>
> +#include <linux/string_helpers.h>
>
> #include <linux/acpi.h>
> #include <linux/io.h>
> @@ -135,8 +136,8 @@ static int set_boost(struct cpufreq_policy *policy, int val)
> {
> on_each_cpu_mask(policy->cpus, boost_set_msr_each,
> (void *)(long)val, 1);
> - pr_debug("CPU %*pbl: Core Boosting %sabled.\n",
> - cpumask_pr_args(policy->cpus), val ? "en" : "dis");
> + pr_debug("CPU %*pbl: Core Boosting %s.\n",
> + cpumask_pr_args(policy->cpus), str_enabled_disabled(val));
>
> return 0;
> }
> --
Applied as 6.2 material, thanks!
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-11-03 18:12 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-08 19:52 [PATCH v1 1/1] cpufreq: ACPI: Use str_enabled_disabled() helper Andy Shevchenko
2022-11-03 18:12 ` 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;
as well as URLs for NNTP newsgroup(s).