Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 303533 | Differences between
and this patch

Collapse All | Expand All

(-)linuxrc.orig (-1 / +4 lines)
Lines 243-250 Link Here
243
	startLUKS
243
	startLUKS
244
	if [ "${NORESUME}" != '1' ] && [ -n "${REAL_RESUME}" ]
244
	if [ "${NORESUME}" != '1' ] && [ -n "${REAL_RESUME}" ]
245
	then
245
	then
246
		good_msg "Attempting resuming from disk using 'resume'..."
247
		suspend_resume
248
		good_msg "Attempting resuming from disk using 'in-kernel'..."
246
		swsusp_resume
249
		swsusp_resume
247
#		suspend_resume
250
		good_msg "Attempting resuming from disk using 'tuxonice'..."
248
		tuxonice_resume
251
		tuxonice_resume
249
	fi
252
	fi
250
fi
253
fi
(-)initrd.scripts.orig (+23 lines)
Lines 902-907 Link Here
902
	return 0
902
	return 0
903
}
903
}
904
904
905
suspend_resume() {
906
	which resume > /dev/null 2>&1 || return
907
	good_msg "Going for resume using 'resume'..."
908
	local args
909
	local features="$(resume --version | grep FEATURES)"
910
	devres=""
911
	if [ -n "${REAL_RESUME}" ]
912
	then
913
		if [ ! -b "${REAL_RESUME}" ]
914
		then
915
			devres="`blkid -t "${REAL_RESUME}" | cut -d ":" -f 1 2>/dev/null`"
916
		else
917
			devres="${REAL_RESUME}"
918
		fi
919
	fi
920
	[ -n "${REAL_RESUME}" ] && args="${args} --resume_device=\"${devres}\""
921
	if ! grep suspend_noui /proc/cmdline > /dev/null 2>&1; then
922
		echo "${features}" | grep "fbsplash" > /dev/null && grep "splash=" /proc/cmdline > /dev/null && args="${args} --parameter=\"splash=y\""
923
	fi
924
	[ -c /dev/snapshot ] || mknod /dev/snapshot c 10 231
925
	eval resume ${args}
926
}
927
905
tuxonice_resume() {
928
tuxonice_resume() {
906
	[ -d /proc/suspend2 -o -d /sys/power/suspend2 -o -d /sys/power/tuxonice ] || return
929
	[ -d /proc/suspend2 -o -d /sys/power/suspend2 -o -d /sys/power/tuxonice ] || return
907
930

Return to bug 303533