Commit f8bb8925682f355dc20f721bda7021ef13e5869f
Committed by
Guenter Roeck
1 parent
ac561494d4
Exists in
master
and in
39 other branches
hwmon: (coretemp) Use pr_fmt and pr_<level>
Added #define pr_fmt KBUILD_MODNAME ": " fmt Converted printks to pr_<level> Coalesced any long formats Removed prefixes from formats Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
Showing 1 changed file with 6 additions and 5 deletions Side-by-side Diff
drivers/hwmon/coretemp.c
... | ... | @@ -20,6 +20,8 @@ |
20 | 20 | * 02110-1301 USA. |
21 | 21 | */ |
22 | 22 | |
23 | +#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt | |
24 | + | |
23 | 25 | #include <linux/module.h> |
24 | 26 | #include <linux/init.h> |
25 | 27 | #include <linux/slab.h> |
... | ... | @@ -445,8 +447,8 @@ |
445 | 447 | * without thermal sensors will be filtered out. |
446 | 448 | */ |
447 | 449 | if (!cpu_has(c, X86_FEATURE_DTS)) { |
448 | - printk(KERN_INFO DRVNAME ": CPU (model=0x%x)" | |
449 | - " has no thermal sensor.\n", c->x86_model); | |
450 | + pr_info("CPU (model=0x%x) has no thermal sensor\n", | |
451 | + c->x86_model); | |
450 | 452 | return 0; |
451 | 453 | } |
452 | 454 | |
... | ... | @@ -466,7 +468,7 @@ |
466 | 468 | pdev = platform_device_alloc(DRVNAME, cpu); |
467 | 469 | if (!pdev) { |
468 | 470 | err = -ENOMEM; |
469 | - printk(KERN_ERR DRVNAME ": Device allocation failed\n"); | |
471 | + pr_err("Device allocation failed\n"); | |
470 | 472 | goto exit; |
471 | 473 | } |
472 | 474 | |
... | ... | @@ -478,8 +480,7 @@ |
478 | 480 | |
479 | 481 | err = platform_device_add(pdev); |
480 | 482 | if (err) { |
481 | - printk(KERN_ERR DRVNAME ": Device addition failed (%d)\n", | |
482 | - err); | |
483 | + pr_err("Device addition failed (%d)\n", err); | |
483 | 484 | goto exit_device_free; |
484 | 485 | } |
485 | 486 |