mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-09 17:11:42 +00:00
Wait for battery boot-up
Some battery uses clock stretching feature, and this could disturb PMU communication before battery going stable. AP does not know and will attempt PMU setting, and could get fail For various battery indicates usually 1s for stable (even if it is much less in real world 200ms~700ms) Let's checking 'battery is ready' when first pump-up power. BUG=chrome-os-partner:28289 TEST=Going battery shipmode and plug-in AC, See booting and EC log Disconnect battery, and plug-in and see booting and EC log Change-Id: I9b62266132d5322366265afe03adbe0db1f9ae75 Signed-off-by: Wonjoon Lee <woojoo.lee@samsung.com> Reviewed-on: https://chromium-review.googlesource.com/197991 Reviewed-by: Randall Spangler <rspangler@chromium.org> Tested-by: Doug Anderson <dianders@chromium.org>
This commit is contained in:
committed by
chrome-internal-fetch
parent
0a166c0467
commit
da5b8fa6c7
@@ -23,6 +23,7 @@
|
||||
* - If XPSHOLD is dropped by the AP, then we power the AP off
|
||||
*/
|
||||
|
||||
#include "battery.h"
|
||||
#include "clock.h"
|
||||
#include "chipset.h" /* This module implements chipset functions too */
|
||||
#include "common.h"
|
||||
@@ -642,6 +643,7 @@ void chipset_task(void)
|
||||
|
||||
gaia_power_init();
|
||||
ap_on = 0;
|
||||
battery_wait_for_stable();
|
||||
|
||||
while (1) {
|
||||
/* Wait until we need to power on, then power on */
|
||||
|
||||
Reference in New Issue
Block a user