Skip to content

Commit

Permalink
USB: fix to usbfs_snoop logging of user defined control urbs
Browse files Browse the repository at this point in the history
When sending CONTROL URB's using the usual CONTROL ioctl, logging works
fine, but when sending them via SUBMITURB, like VMWare does, the
control fields are not logged.  This patch fixes that.

I didn't see any major changes to devio.c recently, so this patch should apply
cleanly to even the latest kernel.  I can resubmit if it doesn't.

From: Chris Frey <cdfrey@foursquare.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Chris Frey authored and Greg Kroah-Hartman committed Dec 20, 2006
1 parent bfb7fb7 commit df251b8
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion drivers/usb/core/devio.c
Original file line number Diff line number Diff line change
Expand Up @@ -962,7 +962,11 @@ static int proc_do_submiturb(struct dev_state *ps, struct usbdevfs_urb *uurb,
kfree(dr);
return -EFAULT;
}
snoop(&ps->dev->dev, "control urb\n");
snoop(&ps->dev->dev, "control urb: bRequest=%02x "
"bRrequestType=%02x wValue=%04x "
"wIndex=%04x wLength=%04x\n",
dr->bRequest, dr->bRequestType, dr->wValue,
dr->wIndex, dr->wLength);
break;

case USBDEVFS_URB_TYPE_BULK:
Expand Down

0 comments on commit df251b8

Please sign in to comment.