diff options
author | Arjan van de Ven <arjan@linux.intel.com> | 2010-12-20 17:10:02 -0800 |
---|---|---|
committer | Arjan van de Ven <arjan@linux.intel.com> | 2010-12-20 17:10:02 -0800 |
commit | 84ea2ed5d34bf4a94fdafc031bf95d342c619538 (patch) | |
tree | ed769fd2297b6499b66adf540af3a82255eef322 /devices/thinkpad-fan.cpp | |
parent | fd4f1ffbf55176e091f6bbb6bfcb35971db3e8c9 (diff) | |
download | powertop-84ea2ed5d34bf4a94fdafc031bf95d342c619538.tar.gz |
fix a bunch of compiler warnings due to careless variable naming choices
Diffstat (limited to 'devices/thinkpad-fan.cpp')
-rw-r--r-- | devices/thinkpad-fan.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/devices/thinkpad-fan.cpp b/devices/thinkpad-fan.cpp index fab1766..75ce5a0 100644 --- a/devices/thinkpad-fan.cpp +++ b/devices/thinkpad-fan.cpp @@ -94,25 +94,25 @@ double thinkpad_fan::power_usage(struct result_bundle *result, struct parameter_ { double power; double factor; - double utilization; + double util; power = 0; - utilization = get_result_value(r_index, result); + util = get_result_value(r_index, result); - if (utilization < 0) - utilization = 0; + if (util < 0) + util = 0; /* physics dictact that fan power goes cubic with the rpms, but there's also a linear component for friction*/ factor = get_parameter_value(fancub_index, bundle); - power += factor * pow(utilization / 3600.0, 3); + power += factor * pow(util / 3600.0, 3); factor = get_parameter_value(fansqr_index, bundle) - 5.0; - power += factor * pow(utilization / 3600.0, 2); + power += factor * pow(util / 3600.0, 2); factor = get_parameter_value(fan_index, bundle) - 10.0; - power += utilization / 5000.0 * factor; + power += util / 5000.0 * factor; if (power <= 0.0) power = 0.0; |