cpufreq: schedutil: Improve prints messages with pr_fmt
authorViresh Kumar <viresh.kumar@linaro.org>
Wed, 18 May 2016 12:25:28 +0000 (17:55 +0530)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 18 May 2016 23:02:52 +0000 (01:02 +0200)
Prefix print messages with KBUILD_MODNAME, i.e 'cpufreq_schedutil: '.
This helps to keep similar formatting for all the print messages
particular to a file and identify those easily in kernel logs.

Its already done this way for rest of the governors.

Along with that, remove the (now) redundant bits from a print message.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
kernel/sched/cpufreq_schedutil.c

index 154ae3a51e8664edd68959611947a808d3c6475f..14c4aa25cc45d4591c339aede161be14ab388a22 100644 (file)
@@ -9,6 +9,8 @@
  * published by the Free Software Foundation.
  */
 
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include <linux/cpufreq.h>
 #include <linux/module.h>
 #include <linux/slab.h>
@@ -388,7 +390,7 @@ static int sugov_init(struct cpufreq_policy *policy)
        mutex_unlock(&global_tunables_lock);
 
        sugov_policy_free(sg_policy);
-       pr_err("cpufreq: schedutil governor initialization failed (error %d)\n", ret);
+       pr_err("initialization failed (error %d)\n", ret);
        return ret;
 }