OSDN Git Service

hwmon: (fam15h_power) Increase output resolution
authorAndre Przywara <andre.przywara@amd.com>
Fri, 23 Mar 2012 09:02:17 +0000 (10:02 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 17 Jun 2012 18:23:11 +0000 (11:23 -0700)
commit18f63bf60d507b4588f33ecfd8657f5d5e2a7b45
treeb7dae3898ad23958ff143652610c8d76d960b2b7
parent4286e566ff410a64f5a329fb42f2d44193c52945
hwmon: (fam15h_power) Increase output resolution

commit 941a956b0e387b21f385f486c34ef67576775cfc upstream.

On high CPU load the accumulating values in the running_avg_cap
register are very low (below 10), so averaging them too early leads
to unnecessary poor output resolution. Since we pretend to output
micro-Watt we better keep all the bits we have as long as possible.

Signed-off-by: Andre Przywara <andre.przywara@amd.com>
Signed-off-by: Andreas Herrmann <andreas.herrmann3@amd.com>
Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/hwmon/fam15h_power.c