MrMEEE / ironhide

Optimus Support for Linux Through VirtualGL - PPA version also available: https://launchpad.net/~mj-casalogic/+archive/ironhide
http://www.martin-juhl.dk
88 stars 0 forks source link

no such device after suspending #156

Open markbaas opened 12 years ago

markbaas commented 12 years ago

In the settings I've enabled "Always enable the nVidia card before disabling" option to "No" in order to not get the 'no such device error'. However after suspending the laptop, again I got this error.

I have fixed this issue by creating a pm-utils hook in sleep.d that enables the card before suspending and runs ironhide-disablecard-on-powerup to disable it. I will post the hook.

markbaas commented 12 years ago

I've put this in /etc/pm/sleep.d/99-ironhide


# This script was necessary to avoid getting no such device errors 
# running optirun after suspend

case $1 in
     suspend|suspend_hybrid|hibernate)
        # enable card to suspend
        /usr/local/bin/ironhide-enablecard
        ;;
     resume|thaw)
        # again, disable the card if no optirun is runninf
        /usr/bin/ironhide-disablecard-on-powerup
        ;;
esac```
komasoftware commented 12 years ago

Same problem here. I will try this and report back. Thx!