Linux: Reset High Speed USB Device Using ehci_hcd Error and Solution

If you are experiencing errors with a high-speed USB device on a Linux system and are seeing messages related to the ehci_hcd driver, you may need to reset the device.

One way to reset a USB device is to use the lsusb command to identify the device and then use the ehci_hcd driver to reset it. Here are the steps to do this:

  1. Run the command lsusb to list all the USB devices connected to the system. Look for the device that you want to reset and note the Bus and Device number.
  2. Use the command echo "0" > /sys/bus/pci/drivers/ehci_hcd/<bus-number>-<device-number>/authorized to reset the device. Replace <bus-number> and <device-number> with the numbers you noted in step 1.

For example, if the bus number is “001” and the device number is “002”, the command would be:

echo "0" > /sys/bus/pci/drivers/ehci_hcd/001-002/authorized
  1. Once the device has been reset, use the command echo "1" > /sys/bus/pci/drivers/ehci_hcd/<bus-number>-<device-number>/authorized to authorize the device again.
  2. You can also use the command ehci_hcd to reset the USB device by using the command ehci_hcd -r <bus-number> <device-number>.
  3. Finally, you can use the command ehci_hcd -e <bus-number> <device-number> to enable the device again.

It’s worth noting that this method may not work on all systems, and if it doesn’t work, you may need to try a different method.

Another way to reset USB device is to unplug and plug the device back in, also you can use udevadm command to reset USB device, for example:

udevadm trigger --action=add /sys/bus/usb/devices/<bus-number>:<device-number>

It’s also important to remember that this method should be used as a last resort, as it can cause data loss or corruption if not used correctly.

Leave a Comment