2 # geninitrd mod: tuxonice
3 USE_TUXONICE=${USE_TUXONICE:-no}
6 # setup geninitrd module
11 if [ "$USE_SUSPEND2" ]; then
12 USE_TUXONICE=$USE_SUSPEND2
13 warn "USE_SUSPEND2 is deprecated, use USE_TUXONICE now instead."
17 # generate initrd fragment
19 initrd_gen_tuxonice() {
20 if ! is_yes "$USE_TUXONICE"; then
26 for arg in $CMDLINE; do
27 if [ "${arg##resume=}" != "${arg}" -o "${arg##resume2=}" != "${arg}" ]; then
31 if [ "$resume" = "yes" ]; then
32 [ -e /proc/suspend2/do_resume ] && echo 1 > /proc/suspend2/do_resume
33 [ -e /sys/power/suspend2/do_resume ] && echo 1 > /sys/power/suspend2/do_resume
34 [ -e /sys/power/tuxonice/do_resume ] && echo 1 > /sys/power/tuxonice/do_resume