diff options
author | Joe Perches <joe@perches.com> | 2010-11-30 08:33:07 +0100 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2010-12-01 08:10:26 +0100 |
commit | da0c490115de026618a7fdcd886602da44392a50 (patch) | |
tree | b61dae8d525fa765151adb8df5456a1e9880a773 /drivers/input/input.c | |
parent | Input: i8042 - use pr_<level>, pr_fmt, fix dbg and __FILE__ use (diff) | |
download | linux-da0c490115de026618a7fdcd886602da44392a50.tar.xz linux-da0c490115de026618a7fdcd886602da44392a50.zip |
Input: use pr_fmt and pr_<level>
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input/input.c')
-rw-r--r-- | drivers/input/input.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/drivers/input/input.c b/drivers/input/input.c index 7f26ca6ecf75..c7a1e826c580 100644 --- a/drivers/input/input.c +++ b/drivers/input/input.c @@ -10,6 +10,8 @@ * the Free Software Foundation. */ +#define pr_fmt(fmt) KBUILD_BASENAME ": " fmt + #include <linux/init.h> #include <linux/types.h> #include <linux/input.h> @@ -959,10 +961,8 @@ static int input_attach_handler(struct input_dev *dev, struct input_handler *han error = handler->connect(handler, dev, id); if (error && error != -ENODEV) - printk(KERN_ERR - "input: failed to attach handler %s to device %s, " - "error: %d\n", - handler->name, kobject_name(&dev->dev.kobj), error); + pr_err("failed to attach handler %s to device %s, error: %d\n", + handler->name, kobject_name(&dev->dev.kobj), error); return error; } @@ -1820,9 +1820,8 @@ void input_set_capability(struct input_dev *dev, unsigned int type, unsigned int break; default: - printk(KERN_ERR - "input_set_capability: unknown type %u (code %u)\n", - type, code); + pr_err("input_set_capability: unknown type %u (code %u)\n", + type, code); dump_stack(); return; } @@ -1904,8 +1903,9 @@ int input_register_device(struct input_dev *dev) return error; path = kobject_get_path(&dev->dev.kobj, GFP_KERNEL); - printk(KERN_INFO "input: %s as %s\n", - dev->name ? dev->name : "Unspecified device", path ? path : "N/A"); + pr_info("%s as %s\n", + dev->name ? dev->name : "Unspecified device", + path ? path : "N/A"); kfree(path); error = mutex_lock_interruptible(&input_mutex); @@ -2187,7 +2187,7 @@ static int __init input_init(void) err = class_register(&input_class); if (err) { - printk(KERN_ERR "input: unable to register input_dev class\n"); + pr_err("unable to register input_dev class\n"); return err; } @@ -2197,7 +2197,7 @@ static int __init input_init(void) err = register_chrdev(INPUT_MAJOR, "input", &input_fops); if (err) { - printk(KERN_ERR "input: unable to register char major %d", INPUT_MAJOR); + pr_err("unable to register char major %d", INPUT_MAJOR); goto fail2; } |