diff options
Diffstat (limited to 'drivers/usb/misc')
-rw-r--r-- | drivers/usb/misc/auerswald.c | 3 | ||||
-rw-r--r-- | drivers/usb/misc/ldusb.c | 6 | ||||
-rw-r--r-- | drivers/usb/misc/sisusbvga/sisusb.c | 4 | ||||
-rw-r--r-- | drivers/usb/misc/usbtest.c | 2 |
4 files changed, 6 insertions, 9 deletions
diff --git a/drivers/usb/misc/auerswald.c b/drivers/usb/misc/auerswald.c index 6f7994f5a714..ae4681f9f0ea 100644 --- a/drivers/usb/misc/auerswald.c +++ b/drivers/usb/misc/auerswald.c | |||
@@ -426,7 +426,7 @@ static int auerchain_submit_urb (pauerchain_t acp, struct urb * urb) | |||
426 | 426 | ||
427 | /* cancel an urb which is submitted to the chain | 427 | /* cancel an urb which is submitted to the chain |
428 | the result is 0 if the urb is cancelled, or -EINPROGRESS if | 428 | the result is 0 if the urb is cancelled, or -EINPROGRESS if |
429 | URB_ASYNC_UNLINK is set and the function is successfully started. | 429 | the function is successfully started. |
430 | */ | 430 | */ |
431 | static int auerchain_unlink_urb (pauerchain_t acp, struct urb * urb) | 431 | static int auerchain_unlink_urb (pauerchain_t acp, struct urb * urb) |
432 | { | 432 | { |
@@ -515,7 +515,6 @@ static void auerchain_unlink_all (pauerchain_t acp) | |||
515 | acep = acp->active; | 515 | acep = acp->active; |
516 | if (acep) { | 516 | if (acep) { |
517 | urbp = acep->urbp; | 517 | urbp = acep->urbp; |
518 | urbp->transfer_flags &= ~URB_ASYNC_UNLINK; | ||
519 | dbg ("unlink active urb"); | 518 | dbg ("unlink active urb"); |
520 | usb_kill_urb (urbp); | 519 | usb_kill_urb (urbp); |
521 | } | 520 | } |
diff --git a/drivers/usb/misc/ldusb.c b/drivers/usb/misc/ldusb.c index ad17892aac9e..7e93ac96490f 100644 --- a/drivers/usb/misc/ldusb.c +++ b/drivers/usb/misc/ldusb.c | |||
@@ -464,7 +464,7 @@ static ssize_t ld_usb_read(struct file *file, char __user *buffer, size_t count, | |||
464 | actual_buffer = (size_t*)(dev->ring_buffer + dev->ring_tail*(sizeof(size_t)+dev->interrupt_in_endpoint_size)); | 464 | actual_buffer = (size_t*)(dev->ring_buffer + dev->ring_tail*(sizeof(size_t)+dev->interrupt_in_endpoint_size)); |
465 | bytes_to_read = min(count, *actual_buffer); | 465 | bytes_to_read = min(count, *actual_buffer); |
466 | if (bytes_to_read < *actual_buffer) | 466 | if (bytes_to_read < *actual_buffer) |
467 | dev_warn(&dev->intf->dev, "Read buffer overflow, %d bytes dropped\n", | 467 | dev_warn(&dev->intf->dev, "Read buffer overflow, %zd bytes dropped\n", |
468 | *actual_buffer-bytes_to_read); | 468 | *actual_buffer-bytes_to_read); |
469 | 469 | ||
470 | /* copy one interrupt_in_buffer from ring_buffer into userspace */ | 470 | /* copy one interrupt_in_buffer from ring_buffer into userspace */ |
@@ -528,8 +528,8 @@ static ssize_t ld_usb_write(struct file *file, const char __user *buffer, | |||
528 | /* write the data into interrupt_out_buffer from userspace */ | 528 | /* write the data into interrupt_out_buffer from userspace */ |
529 | bytes_to_write = min(count, write_buffer_size*dev->interrupt_out_endpoint_size); | 529 | bytes_to_write = min(count, write_buffer_size*dev->interrupt_out_endpoint_size); |
530 | if (bytes_to_write < count) | 530 | if (bytes_to_write < count) |
531 | dev_warn(&dev->intf->dev, "Write buffer overflow, %d bytes dropped\n",count-bytes_to_write); | 531 | dev_warn(&dev->intf->dev, "Write buffer overflow, %zd bytes dropped\n",count-bytes_to_write); |
532 | dbg_info(&dev->intf->dev, "%s: count = %d, bytes_to_write = %d\n", __FUNCTION__, count, bytes_to_write); | 532 | dbg_info(&dev->intf->dev, "%s: count = %zd, bytes_to_write = %zd\n", __FUNCTION__, count, bytes_to_write); |
533 | 533 | ||
534 | if (copy_from_user(dev->interrupt_out_buffer, buffer, bytes_to_write)) { | 534 | if (copy_from_user(dev->interrupt_out_buffer, buffer, bytes_to_write)) { |
535 | retval = -EFAULT; | 535 | retval = -EFAULT; |
diff --git a/drivers/usb/misc/sisusbvga/sisusb.c b/drivers/usb/misc/sisusbvga/sisusb.c index 2fd12264fd53..d63ce6c030f3 100644 --- a/drivers/usb/misc/sisusbvga/sisusb.c +++ b/drivers/usb/misc/sisusbvga/sisusb.c | |||
@@ -229,7 +229,7 @@ sisusb_bulkout_msg(struct sisusb_usb_data *sisusb, int index, unsigned int pipe, | |||
229 | usb_fill_bulk_urb(urb, sisusb->sisusb_dev, pipe, data, len, | 229 | usb_fill_bulk_urb(urb, sisusb->sisusb_dev, pipe, data, len, |
230 | sisusb_bulk_completeout, &sisusb->urbout_context[index]); | 230 | sisusb_bulk_completeout, &sisusb->urbout_context[index]); |
231 | 231 | ||
232 | urb->transfer_flags |= (tflags | URB_ASYNC_UNLINK); | 232 | urb->transfer_flags |= tflags; |
233 | urb->actual_length = 0; | 233 | urb->actual_length = 0; |
234 | 234 | ||
235 | if ((urb->transfer_dma = transfer_dma)) | 235 | if ((urb->transfer_dma = transfer_dma)) |
@@ -295,7 +295,7 @@ sisusb_bulkin_msg(struct sisusb_usb_data *sisusb, unsigned int pipe, void *data, | |||
295 | usb_fill_bulk_urb(urb, sisusb->sisusb_dev, pipe, data, len, | 295 | usb_fill_bulk_urb(urb, sisusb->sisusb_dev, pipe, data, len, |
296 | sisusb_bulk_completein, sisusb); | 296 | sisusb_bulk_completein, sisusb); |
297 | 297 | ||
298 | urb->transfer_flags |= (tflags | URB_ASYNC_UNLINK); | 298 | urb->transfer_flags |= tflags; |
299 | urb->actual_length = 0; | 299 | urb->actual_length = 0; |
300 | 300 | ||
301 | if ((urb->transfer_dma = transfer_dma)) | 301 | if ((urb->transfer_dma = transfer_dma)) |
diff --git a/drivers/usb/misc/usbtest.c b/drivers/usb/misc/usbtest.c index fd7fb98e4b20..54799eb0bc60 100644 --- a/drivers/usb/misc/usbtest.c +++ b/drivers/usb/misc/usbtest.c | |||
@@ -986,7 +986,6 @@ test_ctrl_queue (struct usbtest_dev *dev, struct usbtest_param *param) | |||
986 | 986 | ||
987 | u->context = &context; | 987 | u->context = &context; |
988 | u->complete = ctrl_complete; | 988 | u->complete = ctrl_complete; |
989 | u->transfer_flags |= URB_ASYNC_UNLINK; | ||
990 | } | 989 | } |
991 | 990 | ||
992 | /* queue the urbs */ | 991 | /* queue the urbs */ |
@@ -1052,7 +1051,6 @@ static int unlink1 (struct usbtest_dev *dev, int pipe, int size, int async) | |||
1052 | urb = simple_alloc_urb (testdev_to_usbdev (dev), pipe, size); | 1051 | urb = simple_alloc_urb (testdev_to_usbdev (dev), pipe, size); |
1053 | if (!urb) | 1052 | if (!urb) |
1054 | return -ENOMEM; | 1053 | return -ENOMEM; |
1055 | urb->transfer_flags |= URB_ASYNC_UNLINK; | ||
1056 | urb->context = &completion; | 1054 | urb->context = &completion; |
1057 | urb->complete = unlink1_callback; | 1055 | urb->complete = unlink1_callback; |
1058 | 1056 | ||