[PC-BSD Commits] r18743 - in pcbsd/current/overlays/desktop-overlay: etc usr/local/share/pcbsd/scripts

svn at pcbsd.org svn at pcbsd.org
Fri Aug 31 08:58:15 PDT 2012


Author: kris
Date: 2012-08-31 15:58:15 +0000 (Fri, 31 Aug 2012)
New Revision: 18743

Added:
   pcbsd/current/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/lidchanged.sh
Modified:
   pcbsd/current/overlays/desktop-overlay/etc/devd.conf
Log:

Add new devd.conf entry and helper script for laptops. Now when we close the 
laptop lid, we will change the powerd status to adaptive on AC, and min
on battery. It will revert back to normal when the lid is opened. This will help 
us conserve battery life when the lid is closed, since we cannot safely
enable suspend / resume across the board at this time. 



Modified: pcbsd/current/overlays/desktop-overlay/etc/devd.conf
===================================================================
--- pcbsd/current/overlays/desktop-overlay/etc/devd.conf	2012-08-31 14:49:12 UTC (rev 18742)
+++ pcbsd/current/overlays/desktop-overlay/etc/devd.conf	2012-08-31 15:58:15 UTC (rev 18743)
@@ -280,6 +280,20 @@
 	action "sleep 2 ; /usr/local/share/pcbsd/scripts/gen-pcm-oss.sh";
 };
 
+notify 5 {
+        match "system"          "ACPI";
+        match "subsystem"       "Lid";
+        match "notify"          "0x00";
+        action "/usr/local/share/pcbsd/scripts/lidchanged.sh close";
+};
+
+notify 5 {
+        match "system"          "ACPI";
+        match "subsystem"       "Lid";
+        match "notify"          "0x01";
+        action "/usr/local/share/pcbsd/scripts/lidchanged.sh open";
+};
+
 /* EXAMPLES TO END OF FILE
 
 # The following might be an example of something that a vendor might

Index: pcbsd/current/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/lidchanged.sh
===================================================================
--- pcbsd/current/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/lidchanged.sh	2012-08-31 14:49:12 UTC (rev 18742)
+++ pcbsd/current/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/lidchanged.sh	2012-08-31 15:58:15 UTC (rev 18743)

Property changes on: pcbsd/current/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/lidchanged.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*


More information about the Commits mailing list