FreeBSD Bugzilla – Attachment 54041 Details for
Bug 81774
2nd generation iPod mini cannot be mounted over USB
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
usb_subr.c.diff
usb_subr.c.diff (text/plain; charset=us-ascii), 1.84 KB, created by
Anders Nordby
on 2005-11-26 15:23:58 UTC
(
hide
)
Description:
usb_subr.c.diff
Filename:
MIME Type:
Creator:
Anders Nordby
Created:
2005-11-26 15:23:58 UTC
Size:
1.84 KB
patch
obsolete
>--- sys/dev/usb/usb_subr.c.orig Sat Nov 26 13:59:14 2005 >+++ sys/dev/usb/usb_subr.c Sat Nov 26 15:26:33 2005 >@@ -64,6 +64,7 @@ > #include <sys/bus.h> > #endif > #include <sys/proc.h> >+#include <sys/sysctl.h> > > #include <machine/bus.h> > >@@ -747,6 +748,15 @@ > > /* XXX add function for alternate settings */ > >+/* >+** Clear any stall and make sure DATA0 toggle will be used next >+*/ >+ >+int clearstall = 1; >+SYSCTL_INT(_hw_usb, OID_AUTO, clearstall, CTLFLAG_RW, >+ &clearstall, 1, "clear any stall and make sure data0 toggle will be used next -- breaks some devices"); >+TUNABLE_INT("hw.usb.clearstall", &clearstall); >+ > usbd_status > usbd_setup_pipe(usbd_device_handle dev, usbd_interface_handle iface, > struct usbd_endpoint *ep, int ival, usbd_pipe_handle *pipe) >@@ -778,18 +788,20 @@ > free(p, M_USB); > return (err); > } >- /* Clear any stall and make sure DATA0 toggle will be used next. */ >- if (UE_GET_ADDR(ep->edesc->bEndpointAddress) != USB_CONTROL_ENDPOINT) { >- err = usbd_clear_endpoint_stall(p); >- /* >- * Some devices reject this command, so ignore a STALL. >- * Some device just time out on this command, so ignore >- * that too. >- */ >- if (err && err != USBD_STALLED && err != USBD_TIMEOUT) { >- printf("usbd_setup_pipe: failed to start " >- "endpoint, %s\n", usbd_errstr(err)); >- return (err); >+ if (clearstall) { >+ /* Clear any stall and make sure DATA0 toggle will be used next. */ >+ if (UE_GET_ADDR(ep->edesc->bEndpointAddress) != USB_CONTROL_ENDPOINT) { >+ err = usbd_clear_endpoint_stall(p); >+ /* >+ * Some devices reject this command, so ignore a STALL. >+ * Some device just time out on this command, so ignore >+ * that too. >+ */ >+ if (err && err != USBD_STALLED && err != USBD_TIMEOUT) { >+ printf("usbd_setup_pipe: failed to start " >+ "endpoint, %s\n", usbd_errstr(err)); >+ return (err); >+ } > } > } > *pipe = p;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 81774
:
54040
| 54041