Copie este script em:
/etc/pm/sleep.d/10unbindusb
e torne-o executável.
# Revision: 21.12.2009
# Author: Sandro Mani
function unbind_usb {
for driver in ehci ohci uhci; do
cd "/sys/bus/pci/drivers/${driver}_hcd";
ids=$(ls | grep :);
echo $ids > /tmp/DISABLED_$driver;
for id in $ids; do
echo -n "$id" > unbind;
done;
done;
}
function bind_usb {
for driver in ehci ohci uhci; do
cd "/sys/bus/pci/drivers/${driver}_hcd";
for id in $(cat /tmp/DISABLED_$driver); do
echo -n "$id" > bind;
done;
rm /tmp/DISABLED_$driver;
done;
}
case "$1" in
hibernate|suspend)
unbind_usb;
;;
thaw|resume)
bind_usb;
;;
*)
exit 1;
;;
esac;
exit 0;