summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeffrey Gardner <je_fro@gentoo.org>2008-09-27 22:50:44 +0000
committerJeffrey Gardner <je_fro@gentoo.org>2008-09-27 22:50:44 +0000
commit1d31d4664449a7411cdc08ea8417a55dd14cc71c (patch)
treee0d22406647c80f088ac747bda2df6a2e2fe9432 /x11-drivers/ati-drivers/files/ati-powermode.sh.patch
parentlatest svn (diff)
downloadje_fro-1d31d4664449a7411cdc08ea8417a55dd14cc71c.tar.gz
je_fro-1d31d4664449a7411cdc08ea8417a55dd14cc71c.tar.bz2
je_fro-1d31d4664449a7411cdc08ea8417a55dd14cc71c.zip
latest for testing
svn path=/; revision=241
Diffstat (limited to 'x11-drivers/ati-drivers/files/ati-powermode.sh.patch')
-rw-r--r--x11-drivers/ati-drivers/files/ati-powermode.sh.patch32
1 files changed, 32 insertions, 0 deletions
diff --git a/x11-drivers/ati-drivers/files/ati-powermode.sh.patch b/x11-drivers/ati-drivers/files/ati-powermode.sh.patch
new file mode 100644
index 0000000..cd776e0
--- /dev/null
+++ b/x11-drivers/ati-drivers/files/ati-powermode.sh.patch
@@ -0,0 +1,32 @@
+diff -ur common.orig/usr/share/doc/fglrx/examples/etc/acpi/ati-powermode.sh common/usr/share/doc/fglrx/examples/etc/acpi/ati-powermode.sh
+--- common.orig/usr/share/doc/fglrx/examples/etc/acpi/ati-powermode.sh 2006-07-28 04:22:36.000000000 +0100
++++ common/usr/share/doc/fglrx/examples/etc/acpi/ati-powermode.sh 2006-08-04 12:19:42.000000000 +0100
+@@ -17,6 +17,10 @@
+ fi
+ }
+
++aticonfig='/opt/ati/bin/aticonfig'
++
++# default high power state
++default_state=`$aticonfig --lsp | grep 'default state' | cut -c 3`
+
+ grep -q closed /proc/acpi/button/lid/*/state
+ if [ $? = 0 ]; then
+@@ -46,7 +50,7 @@
+ getXuser;
+ if [ x"$XAUTHORITY" != x"" ]; then
+ export DISPLAY=":$displaynum"
+- su $user -c "/usr/X11R6/bin/aticonfig --set-powerstate=1 --effective=now"
++ su $user -c "$aticonfig --set-powerstate=1 --effective=now"
+ fi
+ done
+ else
+@@ -56,7 +60,7 @@
+ getXuser;
+ if [ x"$XAUTHORITY" != x"" ]; then
+ export DISPLAY=":$displaynum"
+- su $user -c "/usr/X11R6/bin/aticonfig --set-powerstate=3 --effective=now"
++ su $user -c "$aticonfig --set-powerstate=$default_state --effective=now"
+ fi
+ done
+ fi