Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit df63068a authored by Jack Pham's avatar Jack Pham
Browse files

usb: pd: Fix sink hard reset looping bug



commit f2449fb6 ("usb: pd: Clear PD_IN_HARD_RESET in
PE_SNK_TRANSITION_TO_DEFAULT") introduced a subtle bug by
moving the clearing of the pd->hard_reset flag in sink mode
to the PE_SNK_TRANSITION_TO_DEFAULT state. This caused a
regression in which the state machine acts as if it had
received a hard reset signal and infinitely loops back there.
The cycle could only be broken if a physical disconnect happens.
Fix this by renaming the flag to hard_reset_recvd and only using
it when receiving, and not sending a hard reset.

Change-Id: I04008d0bfc9a874e08b45f78a937004e9f37527d
Signed-off-by: default avatarJack Pham <jackp@codeaurora.org>
parent 46aa49c1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment