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: <20230828070000.ooymfbw3qhs5xl5y@vireshk-i7>
Date:   Mon, 28 Aug 2023 12:30:00 +0530
From:   Viresh Kumar <viresh.kumar@...aro.org>
To:     Liao Chang <liaochang1@...wei.com>
Cc:     rafael@...nel.org, linux-pm@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] cpufreq: Fix inconsistency in error messages of
 cpufreq_resume/suspend()

On 26-08-23, 09:52, Liao Chang wrote:
> The error message printed by cpufreq_resume() currently is the pointer
> value of the policy structure, while the error message printed by
> cpufreq_suspend() is the name of the driver. In order to make the error
> messages more consistent and easier to understand, change the error
> message printed by cpufreq_resume() to the name of driver.

Also I don't think printing kernel addresses will help much anyway,
and it also may not be recommended.

> Signed-off-by: Liao Chang <liaochang1@...wei.com>
> ---
>  drivers/cpufreq/cpufreq.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
> index c835ff117386..2199c04ac64d 100644
> --- a/drivers/cpufreq/cpufreq.c
> +++ b/drivers/cpufreq/cpufreq.c
> @@ -1943,8 +1943,8 @@ void cpufreq_resume(void)
>  
>  	for_each_active_policy(policy) {
>  		if (cpufreq_driver->resume && cpufreq_driver->resume(policy)) {
> -			pr_err("%s: Failed to resume driver: %p\n", __func__,
> -				policy);
> +			pr_err("%s: Failed to resume driver: %s\n", __func__,
> +				cpufreq_driver->name);
>  		} else if (has_target()) {
>  			down_write(&policy->rwsem);
>  			ret = cpufreq_start_governor(policy);

There is another print down here which prints policy, please update
that too in a similar way.

-- 
viresh

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ