diff options
-rw-r--r-- | common/usb_pd_protocol.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/common/usb_pd_protocol.c b/common/usb_pd_protocol.c index 857a6b7a46..a983dba257 100644 --- a/common/usb_pd_protocol.c +++ b/common/usb_pd_protocol.c @@ -4380,10 +4380,13 @@ void pd_task(void *u) #ifdef CONFIG_USB_PD_TCPC_LOW_POWER /* - * Always stay in low power mode since we are waiting - * for a connection. + * The next state is not determined just by what is + * attached, but also depends on DRP_STATE. Regardless + * of next state, if nothing is attached, then always + * request low power mode. */ - pd[port].flags |= PD_FLAGS_LPM_REQUESTED; + if (cc_is_open(cc1, cc2)) + pd[port].flags |= PD_FLAGS_LPM_REQUESTED; #endif if (next_state == PD_STATE_SNK_DISCONNECTED) { |