Comment 2 for bug 652076

Revision history for this message
Zuzkins (zuzkins-gmail) wrote :

got into same problem and successfully solved it using a how-to found somewhere (i can't find it again, sadly).
The problem is with usb3 drivers, all you need to do is unbind those and rebind after resume.

0000:00:1a.0 and 0000:00:1d.0 are files found with something like ls /sys/bus/pci/drivers/ehci_hcd/0* adjust the file /etc/pm/sleep.d/20_custom-ehci_hcd with yours devices and suspend/resume should work.

There is still some minor flaw, the keyboard keeps blinking while the computer is suspended, but not a big deal.

cat /etc/pm/sleep.d/20_custom-ehci_hcd
#!/bin/sh
case "${1}" in
        hibernate|suspend)
              # Unbind ehci_hcd for first device XXXX:XX:XX.X:
               echo -n "0000:00:1a.0" | tee /sys/bus/pci/drivers/ehci_hcd/unbind
              # Unbind ehci_hcd for second device XXXX:XX:XX.X:
               echo -n "0000:00:1d.0" | tee /sys/bus/pci/drivers/ehci_hcd/unbind
        ;;
        resume|thaw)
              # Bind ehci_hcd for first device XXXX:XX:XX.X:
              echo -n "0000:00:1a.0" | tee /sys/bus/pci/drivers/ehci_hcd/bind
              # Bind ehci_hcd for second device XXXX:XX:XX.X:
              echo -n "0000:00:1d.0" | tee /sys/bus/pci/drivers/ehci_hcd/bind
        ;;
esac