summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorJack Pham <jackp@codeaurora.org>2016-05-23 11:21:43 -0700
committerKyle Yan <kyan@codeaurora.org>2016-06-08 15:20:27 -0700
commitb5e86ec97a8fe07f6c53ca7e669317616e91ec82 (patch)
tree0cf71735d4c06b246f429860f6e8db2f6a1f554f /include/linux
parent84f558918ff8eb0215f6afd4a18cf53e70a68657 (diff)
usb: pd: Handle disconnection immediately if SDP
Due to a known PMIC HW bug, hard reset or PR swap may result in the charger notifying a CC disconnect event in sink mode, in which case the handler ignores it given these conditions. However, this closely resembles the case of a non-PD capable source getting physically disconnected as well. Consisdering the most probable case of this happening is disconnecting from an SDP while hard reset was just issued (and will fail), this workaround is currently racy if repeated plugin/plugout is performed as the timeout to detect failed hard reset takes a few seconds. For now, until a HW fix is available, optimize this legacy case by allowing the disconnect to go through if the detected charger type is SDP. Also fix the SINK_WAIT_CAP_TIME timeout as it was incorrectly multiplied by 3 during testing and was not removed. This will significantly reduce the amount of time for max failed hard reset attempts for non-PD && non-SDP cases and should decrease the window for racing with an actual disconnect. Change-Id: Ic57a369ed1e194ab512b4b86ce4d216df46b5f46 Signed-off-by: Jack Pham <jackp@codeaurora.org>
Diffstat (limited to 'include/linux')
0 files changed, 0 insertions, 0 deletions