Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1166)

Unified Diff: chromeos-base/power_manager/power_manager-9999.ebuild

Issue 6797001: power_manager : Allow nocrit use flag to disable low batt shutdown. (Closed) Base URL: ssh://gitrw.chromium.org:9222/chromiumos-overlay.git@master
Patch Set: cleaned up 80cols Created 9 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos-base/power_manager/power_manager-9999.ebuild
diff --git a/chromeos-base/power_manager/power_manager-9999.ebuild b/chromeos-base/power_manager/power_manager-9999.ebuild
index 165fafc64116b2b185d5d1239eb1fefdf202104f..7925a82ff2c139f3731cbfb6550578cf27a68398 100644
--- a/chromeos-base/power_manager/power_manager-9999.ebuild
+++ b/chromeos-base/power_manager/power_manager-9999.ebuild
@@ -9,7 +9,7 @@ DESCRIPTION="Power Manager for Chromium OS"
HOMEPAGE="http://src.chromium.org"
LICENSE="BSD"
SLOT="0"
-IUSE="-new_power_button test -lockvt -touchui"
+IUSE="-new_power_button test -lockvt -touchui -nocrit"
KEYWORDS="~amd64 ~arm ~x86"
RDEPEND="chromeos-base/libcros
@@ -122,6 +122,15 @@ src_install() {
insinto "/etc/udev/rules.d"
doins "${S}/99-light-sensor.rules"
+ # Nocrit disables low battery suspend percent by setting it to 0
+ if use nocrit; then
+ crit="usr/share/power_manager/low_battery_suspend_percent"
+ if [ ! -e "${D}/${crit}" ]; then
+ die "low_battery_suspend_percent config file missing"
+ fi
+ echo "0" > "${D}/${crit}"
+ fi
+
if use touchui; then
if [ ! -e "${D}/usr/share/power_manager/use_lid" ]; then
die "use_lid config file missing"
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698