Bump timeout values to allow for slow clock speeds. Ideally, the
timeout should depend on the selected clock speed, but changing the API for that would require quite some effort throughout the entire code base. git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@954 81a1dc3b-b13d-400b-aceb-764788c761c2
This commit is contained in:
parent
a403b4372a
commit
358961e07e
|
@ -1,3 +1,9 @@
|
|||
2011-05-11 Joerg Wunsch <j.gnu@uriah.heep.sax.de>
|
||||
|
||||
* usb_libusb.c: Bump timeout values to allow for slow clock
|
||||
speeds.
|
||||
* jtagmkII.c: (Ditto.)
|
||||
|
||||
2011-03-04 Eric B. Weddington <eric.weddington@atmel.com>
|
||||
|
||||
Thanks to Vitaly Chernookiy for the patch.
|
||||
|
|
|
@ -483,7 +483,7 @@ static int jtagmkII_recv_frame(PROGRAMMER * pgm, unsigned char **msg,
|
|||
unsigned short checksum = 0;
|
||||
|
||||
struct timeval tv;
|
||||
double timeoutval = 5; /* seconds */
|
||||
double timeoutval = 100; /* seconds */
|
||||
double tstart, tnow;
|
||||
|
||||
if (verbose >= 4)
|
||||
|
|
|
@ -269,7 +269,7 @@ static int usbdev_send(union filedescriptor *fd, unsigned char *bp, size_t mlen)
|
|||
*/
|
||||
do {
|
||||
tx_size = (mlen < USBDEV_MAX_XFER)? mlen: USBDEV_MAX_XFER;
|
||||
rv = usb_bulk_write(udev, USBDEV_BULK_EP_WRITE, (char *)bp, tx_size, 5000);
|
||||
rv = usb_bulk_write(udev, USBDEV_BULK_EP_WRITE, (char *)bp, tx_size, 100000);
|
||||
if (rv != tx_size)
|
||||
{
|
||||
fprintf(stderr, "%s: usbdev_send(): wrote %d out of %d bytes, err = %s\n",
|
||||
|
@ -315,7 +315,7 @@ usb_fill_buf(usb_dev_handle *udev, int ep)
|
|||
{
|
||||
int rv;
|
||||
|
||||
rv = usb_bulk_read(udev, ep, usbbuf, USBDEV_MAX_XFER, 5000);
|
||||
rv = usb_bulk_read(udev, ep, usbbuf, USBDEV_MAX_XFER, 100000);
|
||||
if (rv < 0)
|
||||
{
|
||||
if (verbose > 1)
|
||||
|
@ -393,7 +393,7 @@ static int usbdev_recv_frame(union filedescriptor *fd, unsigned char *buf, size_
|
|||
do
|
||||
{
|
||||
rv = usb_bulk_read(udev, fd->usb.ep, usbbuf,
|
||||
USBDEV_MAX_XFER, 10000);
|
||||
USBDEV_MAX_XFER, 100000);
|
||||
if (rv < 0)
|
||||
{
|
||||
if (verbose > 1)
|
||||
|
|
Loading…
Reference in New Issue