Re: [PATCH 15/16] thermal: intel: Use sysfs_emit() for powerclamp cpumask
From: Rafael J. Wysocki
Date: Mon Jun 01 2026 - 14:07:16 EST
On Thu, May 28, 2026 at 8:37 PM Yury Norov <ynorov@xxxxxxxxxx> wrote:
>
> cpumask_get() is used as a sysfs getter for the cpumask module
> parameter. Use sysfs_emit() and cpumask_pr_args() to emit the mask.
>
> This prepares for removing cpumap_print_to_pagebuf().
>
> Signed-off-by: Yury Norov <ynorov@xxxxxxxxxx>
> ---
> drivers/thermal/intel/intel_powerclamp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/thermal/intel/intel_powerclamp.c b/drivers/thermal/intel/intel_powerclamp.c
> index ccf380da12f2..bd7fd98dc310 100644
> --- a/drivers/thermal/intel/intel_powerclamp.c
> +++ b/drivers/thermal/intel/intel_powerclamp.c
> @@ -200,7 +200,7 @@ static int cpumask_get(char *buf, const struct kernel_param *kp)
> if (!cpumask_available(idle_injection_cpu_mask))
> return -ENODEV;
>
> - return cpumap_print_to_pagebuf(false, buf, idle_injection_cpu_mask);
> + return sysfs_emit(buf, "%*pb\n", cpumask_pr_args(idle_injection_cpu_mask));
> }
>
> static const struct kernel_param_ops cpumask_ops = {
> --
Applied as 7.2 material, thanks!