aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2009-07-23 04:14:15 -0400
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2009-07-23 04:16:11 -0400
commit11a79260916b00bcfe1bcfbd7a994321ee25b880 (patch)
treed206aa0e4cfb787c14ebed3a817459cc12e7cfdb /drivers/input
parent4832958218f96f98009c5e01729fbe2b48c7124c (diff)
Input: bf54x-keys - convert printk() to dev_*()
Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/keyboard/bf54x-keys.c26
1 files changed, 9 insertions, 17 deletions
diff --git a/drivers/input/keyboard/bf54x-keys.c b/drivers/input/keyboard/bf54x-keys.c
index d427f322e207..fe376a27fe57 100644
--- a/drivers/input/keyboard/bf54x-keys.c
+++ b/drivers/input/keyboard/bf54x-keys.c
@@ -184,14 +184,13 @@ static int __devinit bfin_kpad_probe(struct platform_device *pdev)
184 int i, error; 184 int i, error;
185 185
186 if (!pdata->rows || !pdata->cols || !pdata->keymap) { 186 if (!pdata->rows || !pdata->cols || !pdata->keymap) {
187 printk(KERN_ERR DRV_NAME 187 dev_err(&pdev->dev, "no rows, cols or keymap from pdata\n");
188 ": No rows, cols or keymap from pdata\n");
189 return -EINVAL; 188 return -EINVAL;
190 } 189 }
191 190
192 if (!pdata->keymapsize || 191 if (!pdata->keymapsize ||
193 pdata->keymapsize > (pdata->rows * pdata->cols)) { 192 pdata->keymapsize > (pdata->rows * pdata->cols)) {
194 printk(KERN_ERR DRV_NAME ": Invalid keymapsize\n"); 193 dev_err(&pdev->dev, "invalid keymapsize\n");
195 return -EINVAL; 194 return -EINVAL;
196 } 195 }
197 196
@@ -211,8 +210,8 @@ static int __devinit bfin_kpad_probe(struct platform_device *pdev)
211 210
212 if (!pdata->debounce_time || pdata->debounce_time > MAX_MULT || 211 if (!pdata->debounce_time || pdata->debounce_time > MAX_MULT ||
213 !pdata->coldrive_time || pdata->coldrive_time > MAX_MULT) { 212 !pdata->coldrive_time || pdata->coldrive_time > MAX_MULT) {
214 printk(KERN_WARNING DRV_NAME 213 dev_warn(&pdev->dev,
215 ": Invalid Debounce/Columndrive Time in platform data\n"); 214 "invalid platform debounce/columndrive time\n");
216 bfin_write_KPAD_MSEL(0xFF0); /* Default MSEL */ 215 bfin_write_KPAD_MSEL(0xFF0); /* Default MSEL */
217 } else { 216 } else {
218 bfin_write_KPAD_MSEL( 217 bfin_write_KPAD_MSEL(
@@ -231,16 +230,14 @@ static int __devinit bfin_kpad_probe(struct platform_device *pdev)
231 230
232 if (peripheral_request_list((u16 *)&per_rows[MAX_RC - pdata->rows], 231 if (peripheral_request_list((u16 *)&per_rows[MAX_RC - pdata->rows],
233 DRV_NAME)) { 232 DRV_NAME)) {
234 printk(KERN_ERR DRV_NAME 233 dev_err(&pdev->dev, "requesting peripherals failed\n");
235 ": Requesting Peripherals failed\n");
236 error = -EFAULT; 234 error = -EFAULT;
237 goto out0; 235 goto out0;
238 } 236 }
239 237
240 if (peripheral_request_list((u16 *)&per_cols[MAX_RC - pdata->cols], 238 if (peripheral_request_list((u16 *)&per_cols[MAX_RC - pdata->cols],
241 DRV_NAME)) { 239 DRV_NAME)) {
242 printk(KERN_ERR DRV_NAME 240 dev_err(&pdev->dev, "requesting peripherals failed\n");
243 ": Requesting Peripherals failed\n");
244 error = -EFAULT; 241 error = -EFAULT;
245 goto out1; 242 goto out1;
246 } 243 }
@@ -254,9 +251,8 @@ static int __devinit bfin_kpad_probe(struct platform_device *pdev)
254 error = request_irq(bf54x_kpad->irq, bfin_kpad_isr, 251 error = request_irq(bf54x_kpad->irq, bfin_kpad_isr,
255 0, DRV_NAME, pdev); 252 0, DRV_NAME, pdev);
256 if (error) { 253 if (error) {
257 printk(KERN_ERR DRV_NAME 254 dev_err(&pdev->dev, "unable to claim irq %d\n",
258 ": unable to claim irq %d; error %d\n", 255 bf54x_kpad->irq);
259 bf54x_kpad->irq, error);
260 goto out2; 256 goto out2;
261 } 257 }
262 258
@@ -297,8 +293,7 @@ static int __devinit bfin_kpad_probe(struct platform_device *pdev)
297 293
298 error = input_register_device(input); 294 error = input_register_device(input);
299 if (error) { 295 if (error) {
300 printk(KERN_ERR DRV_NAME 296 dev_err(&pdev->dev, "unable to register input device\n");
301 ": Unable to register input device (%d)\n", error);
302 goto out4; 297 goto out4;
303 } 298 }
304 299
@@ -316,9 +311,6 @@ static int __devinit bfin_kpad_probe(struct platform_device *pdev)
316 311
317 device_init_wakeup(&pdev->dev, 1); 312 device_init_wakeup(&pdev->dev, 1);
318 313
319 printk(KERN_ERR DRV_NAME
320 ": Blackfin BF54x Keypad registered IRQ %d\n", bf54x_kpad->irq);
321
322 return 0; 314 return 0;
323 315
324out4: 316out4: