[Debian-eeepc-commits] [SCM] Maintenance of eeepc-acpi-scripts debian package branch, shengine, updated. 1.1.0-beta.1-11-g01c7db1
Darren Salt
linux at youmustbejoking.demon.co.uk
Thu May 28 08:46:59 UTC 2009
The following commit has been merged in the shengine branch:
commit 01c7db173912d73b8ef68ecb35e060adadbb5814
Author: Darren Salt <linux at youmustbejoking.demon.co.uk>
Date: Thu May 28 01:31:29 2009 +0100
Get the number of S.H.E. states from b8-b15 of the reported value.
This fixes things on Celeron-based EeePCs' S.H.E.s, which only have two power
control states, unlike the Atom-based ones, which have three.
diff --git a/etc/acpi/lib/shengine.sh b/etc/acpi/lib/shengine.sh
index ba5d540..0481a55 100644
--- a/etc/acpi/lib/shengine.sh
+++ b/etc/acpi/lib/shengine.sh
@@ -3,6 +3,8 @@
# to be sourced
SHENGINE_CTL=/sys/devices/platform/eeepc/cpufv
+SHENGINE_LIMIT="$(cat "$SHENGINE_CTL" 2>/dev/null)"
+SHENGINE_LIMIT=$(( ${SHENGINE_LIMIT:-768} >> 8 ))
get_shengine()
{
@@ -16,7 +18,7 @@ cycle_shengine()
{
if [ -e "$SHENGINE_CTL" ]; then
get_shengine
- echo $(( ($? + 1) % 3)) > "$SHENGINE_CTL"
+ echo $(( ($? + 1) % $SHENGINE_LIMIT)) > "$SHENGINE_CTL"
fi
get_shengine
}
--
Maintenance of eeepc-acpi-scripts debian package
More information about the Debian-eeepc-commits
mailing list