On Fri, 27 Jun 2008, Greg KH wrote:
> From writing USB device firmware, I know the devices I worked with had
> no way to transition from the configured state to the "waiting for
> address to be assigned" except if the device was physically reset by
> loosing power. So I would be very supprised if many devices could do
> this any other way.
For what it's worth, I have never seen or heard of a USB device that
would not go into the "default" state (i.e., waiting for an address to
be assigned) after a port reset -- unless its firmware had already
crashed. When that happens, all you can do is a power cycle.
In answer to Meher's question: Yes, there is a way to force Linux's USB
stack to perform a port reset and re-enumerate a device. It can be
done using usbfs; I have attached a C program to carry it out. Note
however, that reset followed by re-enumeration is _not_ the same thing
as power-cycle followed by reconnect and re-enumeration.
Alan Stern
g
阅读(804) | 评论(0) | 转发(0) |