Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 271
b: refs/heads/master
c: 668a954
h: refs/heads/master
i:
  269: 4a87189
  267: eb77c39
  263: 3d01283
  255: 6267268
v: v3
  • Loading branch information
Christopher Li authored and Greg K-H committed Apr 19, 2005
1 parent 3c9f378 commit 7f071f9
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 22 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a81e7ecca369afee0b07b4758d8c32542ffc587a
refs/heads/master: 668a9541a56af5ebb3ad0babdc2cd73511c9e1e9
40 changes: 19 additions & 21 deletions trunk/drivers/usb/core/devio.c
Original file line number Diff line number Diff line change
Expand Up @@ -1032,15 +1032,15 @@ static int processcompl(struct async *as, void __user * __user *arg)
if (put_user(urb->error_count, &userurb->error_count))
return -EFAULT;

if (!(usb_pipeisoc(urb->pipe)))
return 0;
for (i = 0; i < urb->number_of_packets; i++) {
if (put_user(urb->iso_frame_desc[i].actual_length,
&userurb->iso_frame_desc[i].actual_length))
return -EFAULT;
if (put_user(urb->iso_frame_desc[i].status,
&userurb->iso_frame_desc[i].status))
return -EFAULT;
if (usb_pipeisoc(urb->pipe)) {
for (i = 0; i < urb->number_of_packets; i++) {
if (put_user(urb->iso_frame_desc[i].actual_length,
&userurb->iso_frame_desc[i].actual_length))
return -EFAULT;
if (put_user(urb->iso_frame_desc[i].status,
&userurb->iso_frame_desc[i].status))
return -EFAULT;
}
}

free_async(as);
Expand Down Expand Up @@ -1126,7 +1126,7 @@ static int proc_submiturb_compat(struct dev_state *ps, void __user *arg)
if (get_urb32(&uurb,(struct usbdevfs_urb32 *)arg))
return -EFAULT;

return proc_do_submiturb(ps, &uurb, ((struct usbdevfs_urb __user *)arg)->iso_frame_desc, arg);
return proc_do_submiturb(ps, &uurb, ((struct usbdevfs_urb32 __user *)arg)->iso_frame_desc, arg);
}

static int processcompl_compat(struct async *as, void __user * __user *arg)
Expand All @@ -1146,15 +1146,15 @@ static int processcompl_compat(struct async *as, void __user * __user *arg)
if (put_user(urb->error_count, &userurb->error_count))
return -EFAULT;

if (!(usb_pipeisoc(urb->pipe)))
return 0;
for (i = 0; i < urb->number_of_packets; i++) {
if (put_user(urb->iso_frame_desc[i].actual_length,
&userurb->iso_frame_desc[i].actual_length))
return -EFAULT;
if (put_user(urb->iso_frame_desc[i].status,
&userurb->iso_frame_desc[i].status))
return -EFAULT;
if (usb_pipeisoc(urb->pipe)) {
for (i = 0; i < urb->number_of_packets; i++) {
if (put_user(urb->iso_frame_desc[i].actual_length,
&userurb->iso_frame_desc[i].actual_length))
return -EFAULT;
if (put_user(urb->iso_frame_desc[i].status,
&userurb->iso_frame_desc[i].status))
return -EFAULT;
}
}

free_async(as);
Expand All @@ -1177,10 +1177,8 @@ static int proc_reapurbnonblock_compat(struct dev_state *ps, void __user *arg)
{
struct async *as;

printk("reapurbnblock\n");
if (!(as = async_getcompleted(ps)))
return -EAGAIN;
printk("reap got as %p\n", as);
return processcompl_compat(as, (void __user * __user *)arg);
}

Expand Down

0 comments on commit 7f071f9

Please sign in to comment.