diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/usb/host/isp1760-if.c | 2 | ||||
-rw-r--r-- | drivers/usb/host/r8a66597-hcd.c | 51 | ||||
-rw-r--r-- | drivers/usb/image/mdc800.c | 46 | ||||
-rw-r--r-- | drivers/usb/storage/onetouch.c | 9 |
4 files changed, 63 insertions, 45 deletions
diff --git a/drivers/usb/host/isp1760-if.c b/drivers/usb/host/isp1760-if.c index ad44bd60df98..af849f596135 100644 --- a/drivers/usb/host/isp1760-if.c +++ b/drivers/usb/host/isp1760-if.c | |||
@@ -218,7 +218,7 @@ static int __devinit isp1761_pci_probe(struct pci_dev *dev, | |||
218 | * and reading back and checking the contents are same or not | 218 | * and reading back and checking the contents are same or not |
219 | */ | 219 | */ |
220 | if (reg_data != 0xFACE) { | 220 | if (reg_data != 0xFACE) { |
221 | err("scratch register mismatch %x", reg_data); | 221 | dev_err(&dev->dev, "scratch register mismatch %x\n", reg_data); |
222 | goto clean; | 222 | goto clean; |
223 | } | 223 | } |
224 | 224 | ||
diff --git a/drivers/usb/host/r8a66597-hcd.c b/drivers/usb/host/r8a66597-hcd.c index 2a9bec264ad3..c18d8790c410 100644 --- a/drivers/usb/host/r8a66597-hcd.c +++ b/drivers/usb/host/r8a66597-hcd.c | |||
@@ -118,7 +118,7 @@ static int r8a66597_clock_enable(struct r8a66597 *r8a66597) | |||
118 | r8a66597_write(r8a66597, SCKE, SYSCFG0); | 118 | r8a66597_write(r8a66597, SCKE, SYSCFG0); |
119 | tmp = r8a66597_read(r8a66597, SYSCFG0); | 119 | tmp = r8a66597_read(r8a66597, SYSCFG0); |
120 | if (i++ > 1000) { | 120 | if (i++ > 1000) { |
121 | err("register access fail."); | 121 | printk(KERN_ERR "r8a66597: register access fail.\n"); |
122 | return -ENXIO; | 122 | return -ENXIO; |
123 | } | 123 | } |
124 | } while ((tmp & SCKE) != SCKE); | 124 | } while ((tmp & SCKE) != SCKE); |
@@ -128,7 +128,7 @@ static int r8a66597_clock_enable(struct r8a66597 *r8a66597) | |||
128 | r8a66597_write(r8a66597, USBE, SYSCFG0); | 128 | r8a66597_write(r8a66597, USBE, SYSCFG0); |
129 | tmp = r8a66597_read(r8a66597, SYSCFG0); | 129 | tmp = r8a66597_read(r8a66597, SYSCFG0); |
130 | if (i++ > 1000) { | 130 | if (i++ > 1000) { |
131 | err("register access fail."); | 131 | printk(KERN_ERR "r8a66597: register access fail.\n"); |
132 | return -ENXIO; | 132 | return -ENXIO; |
133 | } | 133 | } |
134 | } while ((tmp & USBE) != USBE); | 134 | } while ((tmp & USBE) != USBE); |
@@ -141,7 +141,7 @@ static int r8a66597_clock_enable(struct r8a66597 *r8a66597) | |||
141 | msleep(1); | 141 | msleep(1); |
142 | tmp = r8a66597_read(r8a66597, SYSCFG0); | 142 | tmp = r8a66597_read(r8a66597, SYSCFG0); |
143 | if (i++ > 500) { | 143 | if (i++ > 500) { |
144 | err("register access fail."); | 144 | printk(KERN_ERR "r8a66597: register access fail.\n"); |
145 | return -ENXIO; | 145 | return -ENXIO; |
146 | } | 146 | } |
147 | } while ((tmp & SCKE) != SCKE); | 147 | } while ((tmp & SCKE) != SCKE); |
@@ -265,7 +265,7 @@ static void get_port_number(char *devpath, u16 *root_port, u16 *hub_port) | |||
265 | if (root_port) { | 265 | if (root_port) { |
266 | *root_port = (devpath[0] & 0x0F) - 1; | 266 | *root_port = (devpath[0] & 0x0F) - 1; |
267 | if (*root_port >= R8A66597_MAX_ROOT_HUB) | 267 | if (*root_port >= R8A66597_MAX_ROOT_HUB) |
268 | err("illegal root port number"); | 268 | printk(KERN_ERR "r8a66597: Illegal root port number.\n"); |
269 | } | 269 | } |
270 | if (hub_port) | 270 | if (hub_port) |
271 | *hub_port = devpath[2] & 0x0F; | 271 | *hub_port = devpath[2] & 0x0F; |
@@ -286,7 +286,7 @@ static u16 get_r8a66597_usb_speed(enum usb_device_speed speed) | |||
286 | usbspd = HSMODE; | 286 | usbspd = HSMODE; |
287 | break; | 287 | break; |
288 | default: | 288 | default: |
289 | err("unknown speed"); | 289 | printk(KERN_ERR "r8a66597: unknown speed\n"); |
290 | break; | 290 | break; |
291 | } | 291 | } |
292 | 292 | ||
@@ -385,7 +385,7 @@ static u8 alloc_usb_address(struct r8a66597 *r8a66597, struct urb *urb) | |||
385 | struct r8a66597_device *dev; | 385 | struct r8a66597_device *dev; |
386 | 386 | ||
387 | if (is_hub_limit(urb->dev->devpath)) { | 387 | if (is_hub_limit(urb->dev->devpath)) { |
388 | err("Externel hub limit reached."); | 388 | dev_err(&urb->dev->dev, "External hub limit reached.\n"); |
389 | return 0; | 389 | return 0; |
390 | } | 390 | } |
391 | 391 | ||
@@ -406,8 +406,9 @@ static u8 alloc_usb_address(struct r8a66597 *r8a66597, struct urb *urb) | |||
406 | return addr; | 406 | return addr; |
407 | } | 407 | } |
408 | 408 | ||
409 | err("cannot communicate with a USB device more than 10.(%x)", | 409 | dev_err(&urb->dev->dev, |
410 | r8a66597->address_map); | 410 | "cannot communicate with a USB device more than 10.(%x)\n", |
411 | r8a66597->address_map); | ||
411 | 412 | ||
412 | return 0; | 413 | return 0; |
413 | } | 414 | } |
@@ -447,7 +448,8 @@ static void r8a66597_reg_wait(struct r8a66597 *r8a66597, unsigned long reg, | |||
447 | do { | 448 | do { |
448 | tmp = r8a66597_read(r8a66597, reg); | 449 | tmp = r8a66597_read(r8a66597, reg); |
449 | if (i++ > 1000000) { | 450 | if (i++ > 1000000) { |
450 | err("register%lx, loop %x is timeout", reg, loop); | 451 | printk(KERN_ERR "r8a66597: register%lx, loop %x " |
452 | "is timeout\n", reg, loop); | ||
451 | break; | 453 | break; |
452 | } | 454 | } |
453 | ndelay(1); | 455 | ndelay(1); |
@@ -675,7 +677,7 @@ static u16 get_empty_pipenum(struct r8a66597 *r8a66597, | |||
675 | array[i++] = 1; | 677 | array[i++] = 1; |
676 | break; | 678 | break; |
677 | default: | 679 | default: |
678 | err("Illegal type"); | 680 | printk(KERN_ERR "r8a66597: Illegal type\n"); |
679 | return 0; | 681 | return 0; |
680 | } | 682 | } |
681 | 683 | ||
@@ -705,7 +707,7 @@ static u16 get_r8a66597_type(__u8 type) | |||
705 | r8a66597_type = R8A66597_ISO; | 707 | r8a66597_type = R8A66597_ISO; |
706 | break; | 708 | break; |
707 | default: | 709 | default: |
708 | err("Illegal type"); | 710 | printk(KERN_ERR "r8a66597: Illegal type\n"); |
709 | r8a66597_type = 0x0000; | 711 | r8a66597_type = 0x0000; |
710 | break; | 712 | break; |
711 | } | 713 | } |
@@ -724,7 +726,7 @@ static u16 get_bufnum(u16 pipenum) | |||
724 | else if (check_interrupt(pipenum)) | 726 | else if (check_interrupt(pipenum)) |
725 | bufnum = 4 + (pipenum - 6); | 727 | bufnum = 4 + (pipenum - 6); |
726 | else | 728 | else |
727 | err("Illegal pipenum (%d)", pipenum); | 729 | printk(KERN_ERR "r8a66597: Illegal pipenum (%d)\n", pipenum); |
728 | 730 | ||
729 | return bufnum; | 731 | return bufnum; |
730 | } | 732 | } |
@@ -740,7 +742,7 @@ static u16 get_buf_bsize(u16 pipenum) | |||
740 | else if (check_interrupt(pipenum)) | 742 | else if (check_interrupt(pipenum)) |
741 | buf_bsize = 0; | 743 | buf_bsize = 0; |
742 | else | 744 | else |
743 | err("Illegal pipenum (%d)", pipenum); | 745 | printk(KERN_ERR "r8a66597: Illegal pipenum (%d)\n", pipenum); |
744 | 746 | ||
745 | return buf_bsize; | 747 | return buf_bsize; |
746 | } | 748 | } |
@@ -1189,7 +1191,7 @@ static int start_transfer(struct r8a66597 *r8a66597, struct r8a66597_td *td) | |||
1189 | prepare_status_packet(r8a66597, td); | 1191 | prepare_status_packet(r8a66597, td); |
1190 | break; | 1192 | break; |
1191 | default: | 1193 | default: |
1192 | err("invalid type."); | 1194 | printk(KERN_ERR "r8a66597: invalid type.\n"); |
1193 | break; | 1195 | break; |
1194 | } | 1196 | } |
1195 | 1197 | ||
@@ -1297,7 +1299,7 @@ static void packet_read(struct r8a66597 *r8a66597, u16 pipenum) | |||
1297 | if (unlikely((tmp & FRDY) == 0)) { | 1299 | if (unlikely((tmp & FRDY) == 0)) { |
1298 | pipe_stop(r8a66597, td->pipe); | 1300 | pipe_stop(r8a66597, td->pipe); |
1299 | pipe_irq_disable(r8a66597, pipenum); | 1301 | pipe_irq_disable(r8a66597, pipenum); |
1300 | err("in fifo not ready (%d)", pipenum); | 1302 | printk(KERN_ERR "r8a66597: in fifo not ready (%d)\n", pipenum); |
1301 | finish_request(r8a66597, td, pipenum, td->urb, -EPIPE); | 1303 | finish_request(r8a66597, td, pipenum, td->urb, -EPIPE); |
1302 | return; | 1304 | return; |
1303 | } | 1305 | } |
@@ -1372,7 +1374,7 @@ static void packet_write(struct r8a66597 *r8a66597, u16 pipenum) | |||
1372 | if (unlikely((tmp & FRDY) == 0)) { | 1374 | if (unlikely((tmp & FRDY) == 0)) { |
1373 | pipe_stop(r8a66597, td->pipe); | 1375 | pipe_stop(r8a66597, td->pipe); |
1374 | pipe_irq_disable(r8a66597, pipenum); | 1376 | pipe_irq_disable(r8a66597, pipenum); |
1375 | err("out write fifo not ready. (%d)", pipenum); | 1377 | printk(KERN_ERR "r8a66597: out fifo not ready (%d)\n", pipenum); |
1376 | finish_request(r8a66597, td, pipenum, urb, -EPIPE); | 1378 | finish_request(r8a66597, td, pipenum, urb, -EPIPE); |
1377 | return; | 1379 | return; |
1378 | } | 1380 | } |
@@ -2007,7 +2009,7 @@ static struct r8a66597_device *get_r8a66597_device(struct r8a66597 *r8a66597, | |||
2007 | return dev; | 2009 | return dev; |
2008 | } | 2010 | } |
2009 | 2011 | ||
2010 | err("get_r8a66597_device fail.(%d)\n", addr); | 2012 | printk(KERN_ERR "r8a66597: get_r8a66597_device fail.(%d)\n", addr); |
2011 | return NULL; | 2013 | return NULL; |
2012 | } | 2014 | } |
2013 | 2015 | ||
@@ -2276,7 +2278,7 @@ static int __init r8a66597_probe(struct platform_device *pdev) | |||
2276 | 2278 | ||
2277 | if (pdev->dev.dma_mask) { | 2279 | if (pdev->dev.dma_mask) { |
2278 | ret = -EINVAL; | 2280 | ret = -EINVAL; |
2279 | err("dma not support"); | 2281 | dev_err(&pdev->dev, "dma not supported\n"); |
2280 | goto clean_up; | 2282 | goto clean_up; |
2281 | } | 2283 | } |
2282 | 2284 | ||
@@ -2284,14 +2286,15 @@ static int __init r8a66597_probe(struct platform_device *pdev) | |||
2284 | (char *)hcd_name); | 2286 | (char *)hcd_name); |
2285 | if (!res) { | 2287 | if (!res) { |
2286 | ret = -ENODEV; | 2288 | ret = -ENODEV; |
2287 | err("platform_get_resource_byname error."); | 2289 | dev_err(&pdev->dev, "platform_get_resource_byname error.\n"); |
2288 | goto clean_up; | 2290 | goto clean_up; |
2289 | } | 2291 | } |
2290 | 2292 | ||
2291 | ires = platform_get_resource(pdev, IORESOURCE_IRQ, 0); | 2293 | ires = platform_get_resource(pdev, IORESOURCE_IRQ, 0); |
2292 | if (!ires) { | 2294 | if (!ires) { |
2293 | ret = -ENODEV; | 2295 | ret = -ENODEV; |
2294 | err("platform_get_resource IORESOURCE_IRQ error."); | 2296 | dev_err(&pdev->dev, |
2297 | "platform_get_resource IORESOURCE_IRQ error.\n"); | ||
2295 | goto clean_up; | 2298 | goto clean_up; |
2296 | } | 2299 | } |
2297 | 2300 | ||
@@ -2301,7 +2304,7 @@ static int __init r8a66597_probe(struct platform_device *pdev) | |||
2301 | reg = ioremap(res->start, resource_len(res)); | 2304 | reg = ioremap(res->start, resource_len(res)); |
2302 | if (reg == NULL) { | 2305 | if (reg == NULL) { |
2303 | ret = -ENOMEM; | 2306 | ret = -ENOMEM; |
2304 | err("ioremap error."); | 2307 | dev_err(&pdev->dev, "ioremap error.\n"); |
2305 | goto clean_up; | 2308 | goto clean_up; |
2306 | } | 2309 | } |
2307 | 2310 | ||
@@ -2309,7 +2312,7 @@ static int __init r8a66597_probe(struct platform_device *pdev) | |||
2309 | hcd = usb_create_hcd(&r8a66597_hc_driver, &pdev->dev, (char *)hcd_name); | 2312 | hcd = usb_create_hcd(&r8a66597_hc_driver, &pdev->dev, (char *)hcd_name); |
2310 | if (!hcd) { | 2313 | if (!hcd) { |
2311 | ret = -ENOMEM; | 2314 | ret = -ENOMEM; |
2312 | err("Failed to create hcd"); | 2315 | dev_err(&pdev->dev, "Failed to create hcd\n"); |
2313 | goto clean_up; | 2316 | goto clean_up; |
2314 | } | 2317 | } |
2315 | r8a66597 = hcd_to_r8a66597(hcd); | 2318 | r8a66597 = hcd_to_r8a66597(hcd); |
@@ -2355,12 +2358,12 @@ static int __init r8a66597_probe(struct platform_device *pdev) | |||
2355 | } | 2358 | } |
2356 | break; | 2359 | break; |
2357 | default: | 2360 | default: |
2358 | err("Unknown irq_sense value."); | 2361 | dev_err(&pdev->dev, "Unknown irq_sense value.\n"); |
2359 | } | 2362 | } |
2360 | 2363 | ||
2361 | ret = usb_add_hcd(hcd, irq, IRQF_DISABLED | irq_trigger); | 2364 | ret = usb_add_hcd(hcd, irq, IRQF_DISABLED | irq_trigger); |
2362 | if (ret != 0) { | 2365 | if (ret != 0) { |
2363 | err("Failed to add hcd"); | 2366 | dev_err(&pdev->dev, "Failed to add hcd\n"); |
2364 | goto clean_up; | 2367 | goto clean_up; |
2365 | } | 2368 | } |
2366 | 2369 | ||
diff --git a/drivers/usb/image/mdc800.c b/drivers/usb/image/mdc800.c index dd432c8feaf8..878c77ca086e 100644 --- a/drivers/usb/image/mdc800.c +++ b/drivers/usb/image/mdc800.c | |||
@@ -355,7 +355,7 @@ static int mdc800_usb_waitForIRQ (int mode, int msec) | |||
355 | if (mdc800->camera_request_ready>0) | 355 | if (mdc800->camera_request_ready>0) |
356 | { | 356 | { |
357 | mdc800->camera_request_ready=0; | 357 | mdc800->camera_request_ready=0; |
358 | err ("timeout waiting for camera."); | 358 | dev_err(&mdc800->dev->dev, "timeout waiting for camera.\n"); |
359 | return -1; | 359 | return -1; |
360 | } | 360 | } |
361 | 361 | ||
@@ -380,7 +380,8 @@ static void mdc800_usb_write_notify (struct urb *urb) | |||
380 | int status = urb->status; | 380 | int status = urb->status; |
381 | 381 | ||
382 | if (status != 0) | 382 | if (status != 0) |
383 | err ("writing command fails (status=%i)", status); | 383 | dev_err(&mdc800->dev->dev, |
384 | "writing command fails (status=%i)\n", status); | ||
384 | else | 385 | else |
385 | mdc800->state=READY; | 386 | mdc800->state=READY; |
386 | mdc800->written = 1; | 387 | mdc800->written = 1; |
@@ -407,7 +408,8 @@ static void mdc800_usb_download_notify (struct urb *urb) | |||
407 | mdc800->state=READY; | 408 | mdc800->state=READY; |
408 | } | 409 | } |
409 | } else { | 410 | } else { |
410 | err ("request bytes fails (status:%i)", status); | 411 | dev_err(&mdc800->dev->dev, |
412 | "request bytes fails (status:%i)\n", status); | ||
411 | } | 413 | } |
412 | mdc800->downloaded = 1; | 414 | mdc800->downloaded = 1; |
413 | wake_up (&mdc800->download_wait); | 415 | wake_up (&mdc800->download_wait); |
@@ -450,7 +452,8 @@ static int mdc800_usb_probe (struct usb_interface *intf, | |||
450 | 452 | ||
451 | if (dev->descriptor.bNumConfigurations != 1) | 453 | if (dev->descriptor.bNumConfigurations != 1) |
452 | { | 454 | { |
453 | err ("probe fails -> wrong Number of Configuration"); | 455 | dev_err(&intf->dev, |
456 | "probe fails -> wrong Number of Configuration\n"); | ||
454 | return -ENODEV; | 457 | return -ENODEV; |
455 | } | 458 | } |
456 | intf_desc = intf->cur_altsetting; | 459 | intf_desc = intf->cur_altsetting; |
@@ -462,7 +465,7 @@ static int mdc800_usb_probe (struct usb_interface *intf, | |||
462 | || ( intf_desc->desc.bNumEndpoints != 4) | 465 | || ( intf_desc->desc.bNumEndpoints != 4) |
463 | ) | 466 | ) |
464 | { | 467 | { |
465 | err ("probe fails -> wrong Interface"); | 468 | dev_err(&intf->dev, "probe fails -> wrong Interface\n"); |
466 | return -ENODEV; | 469 | return -ENODEV; |
467 | } | 470 | } |
468 | 471 | ||
@@ -483,7 +486,7 @@ static int mdc800_usb_probe (struct usb_interface *intf, | |||
483 | } | 486 | } |
484 | if (mdc800->endpoint[i] == -1) | 487 | if (mdc800->endpoint[i] == -1) |
485 | { | 488 | { |
486 | err ("probe fails -> Wrong Endpoints."); | 489 | dev_err(&intf->dev, "probe fails -> Wrong Endpoints.\n"); |
487 | return -ENODEV; | 490 | return -ENODEV; |
488 | } | 491 | } |
489 | } | 492 | } |
@@ -495,7 +498,7 @@ static int mdc800_usb_probe (struct usb_interface *intf, | |||
495 | 498 | ||
496 | retval = usb_register_dev(intf, &mdc800_class); | 499 | retval = usb_register_dev(intf, &mdc800_class); |
497 | if (retval) { | 500 | if (retval) { |
498 | err ("Not able to get a minor for this device."); | 501 | dev_err(&intf->dev, "Not able to get a minor for this device.\n"); |
499 | return -ENODEV; | 502 | return -ENODEV; |
500 | } | 503 | } |
501 | 504 | ||
@@ -645,7 +648,8 @@ static int mdc800_device_open (struct inode* inode, struct file *file) | |||
645 | mdc800->irq_urb->dev = mdc800->dev; | 648 | mdc800->irq_urb->dev = mdc800->dev; |
646 | retval = usb_submit_urb (mdc800->irq_urb, GFP_KERNEL); | 649 | retval = usb_submit_urb (mdc800->irq_urb, GFP_KERNEL); |
647 | if (retval) { | 650 | if (retval) { |
648 | err ("request USB irq fails (submit_retval=%i).", retval); | 651 | dev_err(&mdc800->dev->dev, |
652 | "request USB irq fails (submit_retval=%i).\n", retval); | ||
649 | errn = -EIO; | 653 | errn = -EIO; |
650 | goto error_out; | 654 | goto error_out; |
651 | } | 655 | } |
@@ -735,7 +739,9 @@ static ssize_t mdc800_device_read (struct file *file, char __user *buf, size_t l | |||
735 | mdc800->download_urb->dev = mdc800->dev; | 739 | mdc800->download_urb->dev = mdc800->dev; |
736 | retval = usb_submit_urb (mdc800->download_urb, GFP_KERNEL); | 740 | retval = usb_submit_urb (mdc800->download_urb, GFP_KERNEL); |
737 | if (retval) { | 741 | if (retval) { |
738 | err ("Can't submit download urb (retval=%i)",retval); | 742 | dev_err(&mdc800->dev->dev, |
743 | "Can't submit download urb " | ||
744 | "(retval=%i)\n", retval); | ||
739 | mutex_unlock(&mdc800->io_lock); | 745 | mutex_unlock(&mdc800->io_lock); |
740 | return len-left; | 746 | return len-left; |
741 | } | 747 | } |
@@ -744,7 +750,10 @@ static ssize_t mdc800_device_read (struct file *file, char __user *buf, size_t l | |||
744 | mdc800->downloaded = 0; | 750 | mdc800->downloaded = 0; |
745 | if (mdc800->download_urb->status != 0) | 751 | if (mdc800->download_urb->status != 0) |
746 | { | 752 | { |
747 | err ("request download-bytes fails (status=%i)",mdc800->download_urb->status); | 753 | dev_err(&mdc800->dev->dev, |
754 | "request download-bytes fails " | ||
755 | "(status=%i)\n", | ||
756 | mdc800->download_urb->status); | ||
748 | mutex_unlock(&mdc800->io_lock); | 757 | mutex_unlock(&mdc800->io_lock); |
749 | return len-left; | 758 | return len-left; |
750 | } | 759 | } |
@@ -841,7 +850,8 @@ static ssize_t mdc800_device_write (struct file *file, const char __user *buf, s | |||
841 | 850 | ||
842 | if (mdc800_usb_waitForIRQ (0,TO_GET_READY)) | 851 | if (mdc800_usb_waitForIRQ (0,TO_GET_READY)) |
843 | { | 852 | { |
844 | err ("Camera didn't get ready.\n"); | 853 | dev_err(&mdc800->dev->dev, |
854 | "Camera didn't get ready.\n"); | ||
845 | mutex_unlock(&mdc800->io_lock); | 855 | mutex_unlock(&mdc800->io_lock); |
846 | return -EIO; | 856 | return -EIO; |
847 | } | 857 | } |
@@ -853,7 +863,9 @@ static ssize_t mdc800_device_write (struct file *file, const char __user *buf, s | |||
853 | mdc800->write_urb->dev = mdc800->dev; | 863 | mdc800->write_urb->dev = mdc800->dev; |
854 | retval = usb_submit_urb (mdc800->write_urb, GFP_KERNEL); | 864 | retval = usb_submit_urb (mdc800->write_urb, GFP_KERNEL); |
855 | if (retval) { | 865 | if (retval) { |
856 | err ("submitting write urb fails (retval=%i)", retval); | 866 | dev_err(&mdc800->dev->dev, |
867 | "submitting write urb fails " | ||
868 | "(retval=%i)\n", retval); | ||
857 | mutex_unlock(&mdc800->io_lock); | 869 | mutex_unlock(&mdc800->io_lock); |
858 | return -EIO; | 870 | return -EIO; |
859 | } | 871 | } |
@@ -872,7 +884,9 @@ static ssize_t mdc800_device_write (struct file *file, const char __user *buf, s | |||
872 | case 0x3e: /* Take shot in Fine Mode (WCam Mode) */ | 884 | case 0x3e: /* Take shot in Fine Mode (WCam Mode) */ |
873 | if (mdc800->pic_len < 0) | 885 | if (mdc800->pic_len < 0) |
874 | { | 886 | { |
875 | err ("call 0x07 before 0x05,0x3e"); | 887 | dev_err(&mdc800->dev->dev, |
888 | "call 0x07 before " | ||
889 | "0x05,0x3e\n"); | ||
876 | mdc800->state=READY; | 890 | mdc800->state=READY; |
877 | mutex_unlock(&mdc800->io_lock); | 891 | mutex_unlock(&mdc800->io_lock); |
878 | return -EIO; | 892 | return -EIO; |
@@ -892,7 +906,7 @@ static ssize_t mdc800_device_write (struct file *file, const char __user *buf, s | |||
892 | 906 | ||
893 | if (mdc800_usb_waitForIRQ (1,TO_READ_FROM_IRQ)) | 907 | if (mdc800_usb_waitForIRQ (1,TO_READ_FROM_IRQ)) |
894 | { | 908 | { |
895 | err ("requesting answer from irq fails"); | 909 | dev_err(&mdc800->dev->dev, "requesting answer from irq fails\n"); |
896 | mutex_unlock(&mdc800->io_lock); | 910 | mutex_unlock(&mdc800->io_lock); |
897 | return -EIO; | 911 | return -EIO; |
898 | } | 912 | } |
@@ -920,7 +934,7 @@ static ssize_t mdc800_device_write (struct file *file, const char __user *buf, s | |||
920 | { | 934 | { |
921 | if (mdc800_usb_waitForIRQ (0,TO_DEFAULT_COMMAND)) | 935 | if (mdc800_usb_waitForIRQ (0,TO_DEFAULT_COMMAND)) |
922 | { | 936 | { |
923 | err ("Command Timeout."); | 937 | dev_err(&mdc800->dev->dev, "Command Timeout.\n"); |
924 | mutex_unlock(&mdc800->io_lock); | 938 | mutex_unlock(&mdc800->io_lock); |
925 | return -EIO; | 939 | return -EIO; |
926 | } | 940 | } |
@@ -1031,7 +1045,7 @@ cleanup_on_fail: | |||
1031 | 1045 | ||
1032 | if (mdc800 != NULL) | 1046 | if (mdc800 != NULL) |
1033 | { | 1047 | { |
1034 | err ("can't alloc memory!"); | 1048 | printk(KERN_ERR "mdc800: can't alloc memory!\n"); |
1035 | 1049 | ||
1036 | kfree(mdc800->download_urb_buffer); | 1050 | kfree(mdc800->download_urb_buffer); |
1037 | kfree(mdc800->write_urb_buffer); | 1051 | kfree(mdc800->write_urb_buffer); |
diff --git a/drivers/usb/storage/onetouch.c b/drivers/usb/storage/onetouch.c index 98b89ea9e312..c7bf8954b4e4 100644 --- a/drivers/usb/storage/onetouch.c +++ b/drivers/usb/storage/onetouch.c | |||
@@ -78,8 +78,8 @@ static void usb_onetouch_irq(struct urb *urb) | |||
78 | resubmit: | 78 | resubmit: |
79 | retval = usb_submit_urb (urb, GFP_ATOMIC); | 79 | retval = usb_submit_urb (urb, GFP_ATOMIC); |
80 | if (retval) | 80 | if (retval) |
81 | err ("can't resubmit intr, %s-%s/input0, retval %d", | 81 | dev_err(&dev->dev, "can't resubmit intr, %s-%s/input0, " |
82 | onetouch->udev->bus->bus_name, | 82 | "retval %d\n", onetouch->udev->bus->bus_name, |
83 | onetouch->udev->devpath, retval); | 83 | onetouch->udev->devpath, retval); |
84 | } | 84 | } |
85 | 85 | ||
@@ -90,7 +90,7 @@ static int usb_onetouch_open(struct input_dev *dev) | |||
90 | onetouch->is_open = 1; | 90 | onetouch->is_open = 1; |
91 | onetouch->irq->dev = onetouch->udev; | 91 | onetouch->irq->dev = onetouch->udev; |
92 | if (usb_submit_urb(onetouch->irq, GFP_KERNEL)) { | 92 | if (usb_submit_urb(onetouch->irq, GFP_KERNEL)) { |
93 | err("usb_submit_urb failed"); | 93 | dev_err(&dev->dev, "usb_submit_urb failed\n"); |
94 | return -EIO; | 94 | return -EIO; |
95 | } | 95 | } |
96 | 96 | ||
@@ -117,7 +117,8 @@ static void usb_onetouch_pm_hook(struct us_data *us, int action) | |||
117 | break; | 117 | break; |
118 | case US_RESUME: | 118 | case US_RESUME: |
119 | if (usb_submit_urb(onetouch->irq, GFP_KERNEL) != 0) | 119 | if (usb_submit_urb(onetouch->irq, GFP_KERNEL) != 0) |
120 | err("usb_submit_urb failed"); | 120 | dev_err(&onetouch->irq->dev->dev, |
121 | "usb_submit_urb failed\n"); | ||
121 | break; | 122 | break; |
122 | default: | 123 | default: |
123 | break; | 124 | break; |