charger v2: Don't report 0 battery charge if we're running off battery
charger v2: Don't report 0 battery charge if we're running off battery

Some batteries report 0 charge when their charge level is very low.
powerd has a special interpretation of 0 charge, which causes
low-battery shutdown to not occur. Work-around this powerd behavior by
never reporting 0 charge if our battery is discharging.

BUG=chrome-os-partner:35188
TEST=Manual on Samus. Drain battery to critically low level, verify that
powerd correctly shuts down system.
BRANCH=Samus

Change-Id: I6bd50e038f0e22de7e7de754fa2ea459dc662f35
Signed-off-by: Shawn Nematbakhsh <5259333ce42e3ace6a73988cec7115ed9d3a661a@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/241101
Reviewed-by: Bill Richardson <129945214b1d548d8e49b6c29c43094f8c78057f@chromium.org>
(cherry picked from commit 93bb7195a8d85ff0b7078b794d24ebab2e6828ff)
Signed-off-by: Alec Berg <1a4429eeda29095a12e19a73405f80f5b7f37a63@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/241432

thehobn/ec,thehobn/ec,thehobn/ec,thehobn/ec