PERFORCE change 132644 for review
Hans Petter Selasky
hselasky at FreeBSD.org
Sun Jan 6 14:03:35 PST 2008
http://perforce.freebsd.org/chv.cgi?CH=132644
Change 132644 by hselasky at hselasky_laptop001 on 2008/01/06 22:02:58
Improve alternate setting. Add some more debug prints.
Affected files ...
.. //depot/projects/usb/src/sys/dev/usb/usb_transfer.c#99 edit
Differences ...
==== //depot/projects/usb/src/sys/dev/usb/usb_transfer.c#99 (text+ko) ====
@@ -3368,20 +3368,22 @@
}
if (iface->alt_index == req.wValue[0]) {
/* no change - nothing to do */
+ PRINTFN(0, ("alt setting no change\n"));
break;
}
- error = device_detach(iface->subdev);
- if (error) {
- goto tr_stalled;
- }
+ usbd_detach_device(udev, req.wIndex[0], 1);
+
error = usbd_set_alt_interface_index(udev,
req.wIndex[0], req.wValue[0]);
if (error) {
+ PRINTFN(0, ("alt setting failed %s\n",
+ usbd_errstr(error)));
goto tr_stalled;
}
error = usbd_probe_and_attach(udev,
req.wIndex[0]);
if (error) {
+ PRINTFN(0, ("alt setting probe failed\n"));
goto tr_stalled;
}
break;
More information about the p4-projects
mailing list