mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2025-12-30 10:31:02 +00:00
Allow building without battery charging
Some experimental boards may want to build without a battery charging task to make bringup easier. BUG=chrome-os-partner:18343 TEST=build all boards BRANCH=none Change-Id: I4269fea4046325241ad7720ec3457b0534aadda3 Signed-off-by: Bill Richardson <wfrichar@chromium.org> Reviewed-on: https://gerrit.chromium.org/gerrit/48974 Reviewed-by: Randall Spangler <rspangler@chromium.org>
This commit is contained in:
committed by
ChromeBot
parent
c6e5d592cb
commit
c747652e49
@@ -373,8 +373,10 @@ static void state_machine(uint64_t tnow)
|
||||
* Otherwise we could power on the AP only to shut it right
|
||||
* back down due to insufficient battery.
|
||||
*/
|
||||
#ifdef CONFIG_TASK_CHARGER
|
||||
if (charge_get_state() == PWR_STATE_INIT)
|
||||
break;
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Power the system on if possible. Gating due to insufficient
|
||||
|
||||
@@ -146,7 +146,10 @@ int charge_get_percent(void);
|
||||
/**
|
||||
* Return non-zero if discharging and battery so low we should shut down.
|
||||
*/
|
||||
#ifdef CONFIG_TASK_CHARGER
|
||||
int charge_want_shutdown(void);
|
||||
|
||||
#else
|
||||
static inline int charge_want_shutdown(void) { return 0; }
|
||||
#endif
|
||||
#endif /* __CROS_EC_CHARGE_STATE_H */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user