diff options
author | Joe Perches <joe@perches.com> | 2012-02-15 18:06:19 -0500 |
---|---|---|
committer | Wim Van Sebroeck <wim@iguana.be> | 2012-03-27 13:59:26 -0400 |
commit | 27c766aaacb265d625dc634bf7903f7f9fd0c697 (patch) | |
tree | 06b399d21dec006bc0a3e1c6685b076753e19b94 /drivers/watchdog/iop_wdt.c | |
parent | 7cbc353540c31ffaf65ad44d89b955be0f1d04dc (diff) |
watchdog: Use pr_<fmt> and pr_<level>
Use the current logging styles.
Make sure all output has a prefix.
Add missing newlines.
Remove now unnecessary PFX, NAME, and miscellaneous other #defines.
Coalesce formats.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
Diffstat (limited to 'drivers/watchdog/iop_wdt.c')
-rw-r--r-- | drivers/watchdog/iop_wdt.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/watchdog/iop_wdt.c b/drivers/watchdog/iop_wdt.c index 82fa7a92a8d2..add259b1887c 100644 --- a/drivers/watchdog/iop_wdt.c +++ b/drivers/watchdog/iop_wdt.c | |||
@@ -24,6 +24,8 @@ | |||
24 | * Dan Williams <dan.j.williams@intel.com> | 24 | * Dan Williams <dan.j.williams@intel.com> |
25 | */ | 25 | */ |
26 | 26 | ||
27 | #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt | ||
28 | |||
27 | #include <linux/module.h> | 29 | #include <linux/module.h> |
28 | #include <linux/kernel.h> | 30 | #include <linux/kernel.h> |
29 | #include <linux/fs.h> | 31 | #include <linux/fs.h> |
@@ -85,7 +87,7 @@ static int wdt_disable(void) | |||
85 | write_wdtcr(IOP_WDTCR_DIS); | 87 | write_wdtcr(IOP_WDTCR_DIS); |
86 | clear_bit(WDT_ENABLED, &wdt_status); | 88 | clear_bit(WDT_ENABLED, &wdt_status); |
87 | spin_unlock(&wdt_lock); | 89 | spin_unlock(&wdt_lock); |
88 | printk(KERN_INFO "WATCHDOG: Disabled\n"); | 90 | pr_info("Disabled\n"); |
89 | return 0; | 91 | return 0; |
90 | } else | 92 | } else |
91 | return 1; | 93 | return 1; |
@@ -197,8 +199,8 @@ static int iop_wdt_release(struct inode *inode, struct file *file) | |||
197 | */ | 199 | */ |
198 | if (state != 0) { | 200 | if (state != 0) { |
199 | wdt_enable(); | 201 | wdt_enable(); |
200 | printk(KERN_CRIT "WATCHDOG: Device closed unexpectedly - " | 202 | pr_crit("Device closed unexpectedly - reset in %lu seconds\n", |
201 | "reset in %lu seconds\n", iop_watchdog_timeout()); | 203 | iop_watchdog_timeout()); |
202 | } | 204 | } |
203 | 205 | ||
204 | clear_bit(WDT_IN_USE, &wdt_status); | 206 | clear_bit(WDT_IN_USE, &wdt_status); |
@@ -238,8 +240,7 @@ static int __init iop_wdt_init(void) | |||
238 | with an open */ | 240 | with an open */ |
239 | ret = misc_register(&iop_wdt_miscdev); | 241 | ret = misc_register(&iop_wdt_miscdev); |
240 | if (ret == 0) | 242 | if (ret == 0) |
241 | printk(KERN_INFO "iop watchdog timer: timeout %lu sec\n", | 243 | pr_info("timeout %lu sec\n", iop_watchdog_timeout()); |
242 | iop_watchdog_timeout()); | ||
243 | 244 | ||
244 | return ret; | 245 | return ret; |
245 | } | 246 | } |