From: Florian Fainelli Date: Wed, 21 Aug 2019 23:16:32 +0000 (-0700) Subject: cpufreq: Print driver name if cpufreq_suspend() fails X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=e9a7cc1d97f13f11970f7c484bdfc0502efc4223;p=openwrt%2Fstaging%2Fblogic.git cpufreq: Print driver name if cpufreq_suspend() fails Instead of printing the policy, which is incidentally a kernel pointer, so with limited interest, print the cpufreq driver name that failed to be suspend, which is more useful for debugging. Signed-off-by: Florian Fainelli Acked-by: Viresh Kumar Signed-off-by: Rafael J. Wysocki --- diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c index 26d82e0a2de5..5bfda2bfdf4f 100644 --- a/drivers/cpufreq/cpufreq.c +++ b/drivers/cpufreq/cpufreq.c @@ -1807,8 +1807,8 @@ void cpufreq_suspend(void) } if (cpufreq_driver->suspend && cpufreq_driver->suspend(policy)) - pr_err("%s: Failed to suspend driver: %p\n", __func__, - policy); + pr_err("%s: Failed to suspend driver: %s\n", __func__, + cpufreq_driver->name); } suspend: