mirror of
https://github.com/avrdudes/avrdude.git
synced 2026-09-21 08:36:29 +03:00
Remove usb_set_configuration() call
References from @mcuee that support removal of this call: - https://libusb.sourceforge.io/api-1.0/group__libusb__dev.html#ga785ddea63a2b9bcb879a614ca4867bed - https://github.com/pyusb/pyusb/blob/master/docs/faq.rst#how-not-to-call-set_configuration-on-a-device-already-configured-with-the-selected-configuration
This commit is contained in:
@@ -145,11 +145,6 @@ static int usbdev_open(const char *port, union pinfo pinfo, union filedescriptor
|
||||
goto trynext;
|
||||
}
|
||||
|
||||
if(usb_set_configuration(udev, dev->config[0].bConfigurationValue)) {
|
||||
pmsg_notice("(config %d) %s\n", dev->config[0].bConfigurationValue, usb_strerror());
|
||||
// goto trynext; // Let's hope it has already been configured
|
||||
}
|
||||
|
||||
int usehid = !!(pinfo.usbinfo.flags & PINFO_FL_USEHID);
|
||||
for(iface = 0; iface < dev->config[0].bNumInterfaces; iface++) {
|
||||
cx->usb_interface = dev->config[0].interface[iface].altsetting[0].bInterfaceNumber;
|
||||
|
||||
Reference in New Issue
Block a user