From f4508b6a34051fd466d1508698a62c9eba9c555b Mon Sep 17 00:00:00 2001 From: Con Kolivas Date: Thu, 20 Jun 2013 23:57:58 +1000 Subject: [PATCH] Temporarily limit usb transfer sizes to 512 till we provide a way for each driver to choose the upper limit. --- usbutils.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/usbutils.c b/usbutils.c index c6f5aeb0..91c475b6 100644 --- a/usbutils.c +++ b/usbutils.c @@ -2186,8 +2186,12 @@ usb_bulk_transfer(struct libusb_device_handle *dev_handle, /* Limit length of transfer to the largest this descriptor supports * and leave the higher level functions to transfer more if needed. */ +#if 0 if (length > cgpu->usbdev->found->wMaxPacketSize) length = cgpu->usbdev->found->wMaxPacketSize; +#endif + if (length > 512) + length = 512; cg_rlock(&cgusb_fd_lock); err = libusb_bulk_transfer(dev_handle, endpoint, data, length,