diff options
author | N0YB <Al_Stu@Frontier.com> | 2013-02-08 17:09:42 -0800 |
---|---|---|
committer | N0YB <Al_Stu@Frontier.com> | 2013-02-08 17:09:42 -0800 |
commit | a358eec2aecf523fdb623dd4ac529a8764355a86 (patch) | |
tree | 077d4266607b4307be8a505a8fa63d2b5901c646 /etc/inc/system.inc | |
parent | 34bf3512d18304c8f3579fa8aea5b7d403039230 (diff) | |
download | pfsense-a358eec2aecf523fdb623dd4ac529a8764355a86.zip pfsense-a358eec2aecf523fdb623dd4ac529a8764355a86.tar.gz |
System: Advanced: Miscellaneous: PowerD
Add the on battery mode option settings.
Diffstat (limited to 'etc/inc/system.inc')
-rw-r--r-- | etc/inc/system.inc | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/etc/inc/system.inc b/etc/inc/system.inc index dfd29bc..e5c6c93 100644 --- a/etc/inc/system.inc +++ b/etc/inc/system.inc @@ -47,10 +47,16 @@ function activate_powerd() { if(isset($config['system']['powerd_enable'])) { if ($g["platform"] == "nanobsd") exec("/sbin/kldload cpufreq"); - $mode = "hadp"; - if (!empty($config['system']['powerd_mode'])) - $mode = $config['system']['powerd_mode']; - mwexec("/usr/sbin/powerd -b $mode -a $mode"); + + $ac_mode = "hadp"; + if (!empty($config['system']['powerd_ac_mode'])) + $ac_mode = $config['system']['powerd_ac_mode']; + + $battery_mode = "hadp"; + if (!empty($config['system']['powerd_battery_mode'])) + $battery_mode = $config['system']['powerd_battery_mode']; + + mwexec("/usr/sbin/powerd -b $battery_mode -a $ac_mode"); } } |