aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/xhci-mem.c
diff options
context:
space:
mode:
authorSarah Sharp <sarah.a.sharp@linux.intel.com>2009-04-27 22:58:50 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2009-06-16 00:44:49 -0400
commitb10de142119a676552df3f0d2e3a9d647036c26a (patch)
treecd38fe5efed6776e7c9e154a05202bae4f683295 /drivers/usb/host/xhci-mem.c
parentf94e0186312b0fc39f41eed4e21836ed74b7efe1 (diff)
USB: xhci: Bulk transfer support
Allow device drivers to submit URBs to bulk endpoints on devices under an xHCI host controller. Share code between the control and bulk enqueueing functions when it makes sense. To get the best performance out of bulk transfers, SuperSpeed devices must have the bMaxBurst size copied from their endpoint companion controller into the xHCI device context. This allows the host controller to "burst" up to 16 packets before it has to wait for the device to acknowledge the first packet. The buffers in Transfer Request Blocks (TRBs) can cross page boundaries, but they cannot cross 64KB boundaries. The buffer must be broken into multiple TRBs if a 64KB boundary is crossed. The sum of buffer lengths in all the TRBs in a Transfer Descriptor (TD) cannot exceed 64MB. To work around this, the enqueueing code must enqueue multiple TDs. The transfer event handler may incorrectly give back the URB in this case, if it gets a transfer event that points somewhere in the first TD. FIXME later. Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/host/xhci-mem.c')
-rw-r--r--drivers/usb/host/xhci-mem.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/usb/host/xhci-mem.c b/drivers/usb/host/xhci-mem.c
index 8cd55f03ea26..617db9c37770 100644
--- a/drivers/usb/host/xhci-mem.c
+++ b/drivers/usb/host/xhci-mem.c
@@ -494,7 +494,9 @@ int xhci_endpoint_init(struct xhci_hcd *xhci,
494 case USB_SPEED_SUPER: 494 case USB_SPEED_SUPER:
495 max_packet = ep->desc.wMaxPacketSize; 495 max_packet = ep->desc.wMaxPacketSize;
496 ep_ctx->ep_info2 |= MAX_PACKET(max_packet); 496 ep_ctx->ep_info2 |= MAX_PACKET(max_packet);
497 /* FIXME dig out burst from ep companion desc */ 497 /* dig out max burst from ep companion desc */
498 max_packet = ep->ep_comp->desc.bMaxBurst;
499 ep_ctx->ep_info2 |= MAX_BURST(max_packet);
498 break; 500 break;
499 case USB_SPEED_HIGH: 501 case USB_SPEED_HIGH:
500 /* bits 11:12 specify the number of additional transaction 502 /* bits 11:12 specify the number of additional transaction