pkgsrc/cross/avrdude/patches/patch-ag
mef d50827c0ff Update avrdude 6.0.1 to 6.1
----------------------------------------------------------------------
  * Major changes compared to the previous version:
    - Atmel EDBG protocol support added (JTAGICE3, XplainedPro, Atmel-ICE)

  * New programmers supported:
    - Atmel DFU, using FLIP protocol version 1 (AT90USB and ATmega*U* devices),
      or version 2 (Xmega devices)
    - Atmel-ICE (ARM/AVR), JTAG, PDI, debugWIRE, ISP modi

  * Bugfixes
    - bug #40055: AVRDUDE segfaults when writing eeprom
    - bug #40085: Typo fix in fuses report (for 6.1-svn-20130917)
    - bug #40782: Verify errors for object size > 16 k on x32e5 due
      to typo in avrdude.conf
    - bug #40817: Elf file support (possibly) not working on 6.0.1 windows build
    - bug #40897: AT Mega2560 not correctly programmed with stk500(v1)
      ISP (solution patch)
    - bug #41357: OS X: Avrdude messes with the usb stack?
    - bug #41402: dfu.c missing include <stdint.h>
    - patch #7896: DFU FLIPv2 programming support
    - patch #XXXX: xxx

  * Internals:
    - (Some) programmers can take a list of USB PIDs now.
2014-10-07 15:10:29 +00:00

24 lines
782 B
Text

$NetBSD: patch-ag,v 1.7 2014/10/07 15:10:29 mef Exp $
Work around AVRISP mkII initial sync stalls on NetBSD.
--- usb_libusb.c.orig 2014-03-13 08:03:19.000000000 +0900
+++ usb_libusb.c 2014-10-08 00:01:40.000000000 +0900
@@ -324,6 +324,17 @@ static void usbdev_close(union filedescr
if (udev == NULL)
return;
+#if defined(__NetBSD__)
+#define USB_FEAT_ENDPOINT_HALT 0
+ /*
+ * Clear Feature Endpoint Halt to reset device's data toggle to DATA0.
+ * This way, when we reopen expecting DATA0, things don't time out.
+ */
+ usb_control_msg(udev, USB_TYPE_STANDARD | USB_RECIP_ENDPOINT,
+ USB_REQ_CLEAR_FEATURE, USB_FEAT_ENDPOINT_HALT,
+ fd->usb.rep & 0xf, NULL, 0, 100);
+#endif
+
(void)usb_release_interface(udev, usb_interface);
#if defined(__linux__)