Skip to content

Commit da38745

Browse files
JohnWC-YehJohnAZoidberg
authored andcommitted
fwk: tulip: resume from suspend can enter epr mode
Previously, entering EPR mode was only allowed when the system was fully in the S0 state. However, during resume from S0ix → S0, the system transitions through intermediate states before reaching S0. Since the original condition strictly checked for CHIPSET_STATE_ON, the EC blocked EPR entry during this transition, causing the system to remain in SPR mode after resume. BRANCH=fwk-tulip-29169 BUG=https://app.clickup.com/t/86evdvfx2 TEST=1.connect 180w/240w AC 2.system enter sleep, check power-z vbus=20v 3.resume from sleep, can enter epr and power-z vbus=36v or48v Signed-off-by: johnwc_yeh <JohnWC_Yeh@compal.com>
1 parent 15e2d78 commit da38745

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

zephyr/program/framework/src/cypd_ccg8.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -547,7 +547,7 @@ static void buck_ready_for_epr(void)
547547
int mode = is_enter_epr ? LEVEL_BUCK_ENTER_EPR : LEVEL_BUCK_EXIT_EPR;
548548

549549
/* make sure enter EPR mode only process in S0 state */
550-
if (is_enter_epr && (!chipset_in_state(CHIPSET_STATE_ON) ||
550+
if (is_enter_epr && (!chipset_in_or_transitioning_to_state(CHIPSET_STATE_ON) ||
551551
!extpower_is_present())) {
552552
CPRINTS("Enter EPR aborted: not in S0 or no power");
553553
epr_buck_ctx.phase = BUCK_PHASE_IDLE;

0 commit comments

Comments
 (0)