Skip to content

Commit 45bb4d1

Browse files
LeoCX-Tsaiquinchou77
authored andcommitted
fwk: main: set PD Vbus fet control again when a new power request
Sometimes device wouldn't send the max request the first time negotiation, so we need to open again the PD Vbus fet if had a new power request(CCG_RESPONSE_PD_CONTRACT_NEGOTIATION_COMPLETE) BRANCH=fwk-main BUG=https://app.clickup.com/t/86eqbzy9b TEST=test on lilac, use Anker GANPrime 65w can charge the Unit Signed-off-by: LeoCX_Tsai <[email protected]> (cherry picked from commit 0de02d9a845d74fe444813bf467225ef16530a69)
1 parent b06d3e8 commit 45bb4d1

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

zephyr/program/framework/src/cypress_pd_common.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2025,7 +2025,13 @@ void pd_request_power_swap(int port)
20252025

20262026
void pd_set_new_power_request(int port)
20272027
{
2028-
/* We probably dont need to do this since we will always request max. */
2028+
/*
2029+
* if the old port have change the request
2030+
* need to reopen the vbus port again,
2031+
* eg: after PD send again CCG_RESPONSE_PD_CONTRACT_NEGOTIATION_COMPLETE
2032+
* will set a new power request, the VBUS port need to open again.
2033+
*/
2034+
board_set_active_charge_port(port);
20292035
return;
20302036
}
20312037

0 commit comments

Comments
 (0)