aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/ff-core.c
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2010-11-30 02:33:07 -0500
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2010-12-01 02:10:26 -0500
commitda0c490115de026618a7fdcd886602da44392a50 (patch)
treeb61dae8d525fa765151adb8df5456a1e9880a773 /drivers/input/ff-core.c
parent4eb3c30b2e034b673df3e8f21b497e39f3911a02 (diff)
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/ff-core.c')
-rw-r--r--drivers/input/ff-core.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/drivers/input/ff-core.c b/drivers/input/ff-core.c
index 03078c08309a..3367f760d75a 100644
--- a/drivers/input/ff-core.c
+++ b/drivers/input/ff-core.c
@@ -23,7 +23,7 @@
23 23
24/* #define DEBUG */ 24/* #define DEBUG */
25 25
26#define debug(format, arg...) pr_debug("ff-core: " format "\n", ## arg) 26#define pr_fmt(fmt) KBUILD_BASENAME ": " fmt
27 27
28#include <linux/input.h> 28#include <linux/input.h>
29#include <linux/module.h> 29#include <linux/module.h>
@@ -116,7 +116,7 @@ int input_ff_upload(struct input_dev *dev, struct ff_effect *effect,
116 116
117 if (effect->type < FF_EFFECT_MIN || effect->type > FF_EFFECT_MAX || 117 if (effect->type < FF_EFFECT_MIN || effect->type > FF_EFFECT_MAX ||
118 !test_bit(effect->type, dev->ffbit)) { 118 !test_bit(effect->type, dev->ffbit)) {
119 debug("invalid or not supported effect type in upload"); 119 pr_debug("invalid or not supported effect type in upload\n");
120 return -EINVAL; 120 return -EINVAL;
121 } 121 }
122 122
@@ -124,7 +124,7 @@ int input_ff_upload(struct input_dev *dev, struct ff_effect *effect,
124 (effect->u.periodic.waveform < FF_WAVEFORM_MIN || 124 (effect->u.periodic.waveform < FF_WAVEFORM_MIN ||
125 effect->u.periodic.waveform > FF_WAVEFORM_MAX || 125 effect->u.periodic.waveform > FF_WAVEFORM_MAX ||
126 !test_bit(effect->u.periodic.waveform, dev->ffbit))) { 126 !test_bit(effect->u.periodic.waveform, dev->ffbit))) {
127 debug("invalid or not supported wave form in upload"); 127 pr_debug("invalid or not supported wave form in upload\n");
128 return -EINVAL; 128 return -EINVAL;
129 } 129 }
130 130
@@ -246,7 +246,7 @@ static int flush_effects(struct input_dev *dev, struct file *file)
246 struct ff_device *ff = dev->ff; 246 struct ff_device *ff = dev->ff;
247 int i; 247 int i;
248 248
249 debug("flushing now"); 249 pr_debug("flushing now\n");
250 250
251 mutex_lock(&ff->mutex); 251 mutex_lock(&ff->mutex);
252 252
@@ -315,8 +315,7 @@ int input_ff_create(struct input_dev *dev, int max_effects)
315 int i; 315 int i;
316 316
317 if (!max_effects) { 317 if (!max_effects) {
318 printk(KERN_ERR 318 pr_err("cannot allocate device without any effects\n");
319 "ff-core: cannot allocate device without any effects\n");
320 return -EINVAL; 319 return -EINVAL;
321 } 320 }
322 321