From: Mariusz Ceier Date: Sat, 9 Aug 2014 09:43:31 +0000 (+0200) Subject: ACPI / battery: Fix warning message in acpi_battery_get_state() X-Git-Tag: omap-for-v3.17/fixes-against-rc2~56^2~2^4 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d719870b41e00baf64d028c2668ae1fc3eb50e79;p=pandora-kernel.git ACPI / battery: Fix warning message in acpi_battery_get_state() capacity_now should be assigned after comparing it to design_capacity. Otherwise warning is printed even when capacity_now before assignment is equal to design_capacity, making the check useless and "current charge level" wrong (it should be higher than, not equal to, "maximum charge level", which is full_charge_capacity): "battery: reported current charge level (56410) is higher than reported maximum charge level (56410)." Fixes: 232de5143790 (ACPI / battery: fix wrong value of capacity_now reported when fully charged) Signed-off-by: Mariusz Ceier Cc: 3.16+ # 3.16+ [rjw: Subject] Signed-off-by: Rafael J. Wysocki --- Reading git-diff-tree failed