svn commit: r267044 - head/sys/dev/usb/controller

Hans Petter Selasky hselasky at FreeBSD.org
Wed Jun 4 10:29:02 UTC 2014


Author: hselasky
Date: Wed Jun  4 10:29:01 2014
New Revision: 267044
URL: http://svnweb.freebsd.org/changeset/base/267044

Log:
  The external USB HUB in the RPI-B rejects control endpoint traffic
  using the BULK endpoint type, while other USB HUBs do not. Disable
  endpoint type workaround for TT traffic.
  
  MFC after:	3 days

Modified:
  head/sys/dev/usb/controller/dwc_otg.c

Modified: head/sys/dev/usb/controller/dwc_otg.c
==============================================================================
--- head/sys/dev/usb/controller/dwc_otg.c	Wed Jun  4 09:54:01 2014	(r267043)
+++ head/sys/dev/usb/controller/dwc_otg.c	Wed Jun  4 10:29:01 2014	(r267044)
@@ -3161,11 +3161,20 @@ dwc_otg_setup_standard_chain(struct usb_
 			(xfer->max_packet_size << HCCHAR_MPS_SHIFT) |
 			HCCHAR_CHENA;
 
-		/* XXX stability hack - possible HW issue */
-		if (td->ep_type == UE_CONTROL)
+		/*
+		 * XXX stability hack - possible HW issue
+		 *
+		 * Disable workaround when using a transaction
+		 * translator, hence some TTs reject control endpoint
+		 * traffic using BULK endpoint type:
+		 */
+		if (td->ep_type == UE_CONTROL &&
+		    (xfer->xroot->udev->speed == USB_SPEED_HIGH ||
+		     xfer->xroot->udev->parent_hs_hub == NULL)) {
 			hcchar |= (UE_BULK << HCCHAR_EPTYPE_SHIFT);
-		else
+		} else {
 			hcchar |= (td->ep_type << HCCHAR_EPTYPE_SHIFT);
+		}
 
 		if (usbd_get_speed(xfer->xroot->udev) == USB_SPEED_LOW)
 			hcchar |= HCCHAR_LSPDDEV;


More information about the svn-src-head mailing list