On Sun, 23 Apr 2006, usb usb wrote: > Alan, > > Thanks again for educating me! > > > I'm not sure what you mean by "hard reset". That > > term isn't used in the > > USB specification. > > Well, by "hard reset" I meant something similar to > "cold start". > > > In that case the usb_reset_device routine will > > return an error code, so > > your driver will know that something funny happened > > during the reset. > > You can simply have your probe routine return the > > same error code. The > > USB core treats it the same as though the device had > > been unplugged and > > then plugged in again. This means your driver (or > > possibly a different > > driver) will be re-probed with a new usb_device > > structure. > > I'm sorry I didn't understand this. usb_reset_device's > only error return is ENODEV. Does this cause the > re-probing? So, this is considered as a new device - > right?
More or less right. The idea is that if anything goes wrong, the old device structure is removed -- hence the ENODEV. When a new device structure is created, the drivers will be re-probed. So your code doesn't need to do anything special. > And, what's the advantage/disadvantage of going with > this route or with usb_reset_dev? This _is_ the usb_reset_device route. Alan Stern ------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Linux-usb-users@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-users