On Mon, 19 Aug 2013, Oleksij Rempel wrote: > >> I assume, no i need to add to the driver some kind of firmware check. > >> What is the proper way to do it? > > > > The simplest way is to put a new value for the device descriptor's > > bcdDevice value in the firmware. Then all you have to do is check that > > value. > > Hi Alan, > > I need some more help. I reworked some firmware related parts of > ath9k_htc driver and added usb_reset_device. As well dummy pre_reset and > post_reset functions. > Right now it will do double reset. First time after usb_reset_device > host will detect changes in usb descriptor and set flag for logical > disconnect. In this case driver will fail to load and after this actual > disconnect btw reset will happen. Then, after reset, driver will be > automatically loaded second time. This time usb_reset_device will go > without problems, since usb descriptor was updated on first round. > > How driver should behave in this situation? I prefer to update firmware > on every module load. Why? If the firmware has already been updated, why waste time updating it again? If you don't update the firmware when it is already present, then the device won't get reset a second time. Alan Stern -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html