From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rajesh Bhagat Date: Mon, 30 May 2016 16:53:53 +0530 Subject: [U-Boot] [PATCH 0/2] common: usb_storage : Implement logic to calculate optimal Message-ID: <1464607435-2639-1-git-send-email-rajesh.bhagat@nxp.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Implements the logic to calculate the optimal usb maximum trasfer blocks instead of sending USB_MAX_XFER_BLK blocks which is 65535 and 20 in case of EHCI and other USB protocols respectively Sample Behaviour: Fallback to 16384 blocks once failure is seen on 32768. => usb write a0000000 0 10000; USB write: device 0 block # 0, count 65536 ... usb_write: retry #2, xfer_blk 4096, smallblks 4096 usb_write: retry #2, xfer_blk 8192, smallblks 8192 usb_write: retry #2, xfer_blk 16384, smallblks 16384 usb_write: retry #2, xfer_blk 32768, smallblks 32768 EHCI timed out on TD - token=0x10008c80 usb_write: retry #1, xfer_blk 16384, smallblks 16384 usb_write: retry #2, xfer_blk 16384, smallblks 16384 usb_write: retry #2, xfer_blk 16384, smallblks 4096 65536 blocks write: OK Rajesh Bhagat (2): common: usb_storage : Implement logic to calculate optimal usb maximum trasfer blocks common: usb_storage : Seperate optimal blocks logic calculation for read/write common/usb_storage.c | 66 +++++++++++++++++++++++++++++++++++++--------------- 1 file changed, 47 insertions(+), 19 deletions(-) -- 2.6.2.198.g614a2ac