Some Type-C multi-port adapters which do not support usb connection
are advertising the multi-functionality in DP alt mode. If
multi-functionality is preferred, the DP driver assumes the adapter
supports usb connection and USB phy driver will program the PHY mode
to DP+USB.
In source mode, usb PD driver checks for the peer_usb_connection
of the adapter. If it does not support usb then it will stop usb stack
and update the PHY MODE to USB only mode from phy_suspend path.
The result is, usb may program the combo PHY to usb only mode when DP
is already connected. This is causing AUX read/write timeouts when DP
is trying to access the phy registers.
To fix this issue, a flag in SVID connect handler in usbpd driver to
notify peer_usb_comm support to the DP driver. DP driver will read this
flag and program the phy mode.
Change-Id: Iae6a9596000313ede51d8af3c4989c74ac2f0b10
Signed-off-by: Pratham Pratap <prathampratap@codeaurora.org>
Add an API to allow a VDM client (e.g. DisplayPort) to indicate
that the system is entering suspend but that an incoming VDM
message is expected. If a VDM is then received, it will bypass
kick_sm() which would otherwise abort the suspend and instead
be handed to the client VDM handler directly.
The flag can be reset either explicitly, if a soft/hard reset
occur, or if a VDM TX is requested, as those situations would
require the state machine to run in the worker thread normally.
Change-Id: I8af7e13abad766f9e4245149da9457f1c62a25d5
Signed-off-by: Jack Pham <jackp@codeaurora.org>
This snapshot includes DP and supporting files for compilation.
This change also has the copyright year update to the files. Snapshot
was taken from msm-4.14 as of commit 1df57774a520
("ARM: dts: msm: Remove dma-coherent for IPA for sdxprairie").
Change-Id: I7152ec12a1c3c8346e158540c8bf70d4bbc2c372
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
Fix compilation errors introduced during the snapshot from
msm-4.14 and subsequent cherry-picks.
- Add missing linux/usb/usbpd.h header
- Upstream moved extcon definitions to <linux/extcon-provider.h>
- Fix missing space after '=' in Makefile, otherwise 'pd'
subdirectory fails to be included
- Fix a few places where break/return were incorrectly used
- MSG_BATTERY_STATUS is not an extended message so handling
should have been done in handle_data_snk_ready()
Change-Id: I248b17a8479572b53b2a792877460d6474bca113
Signed-off-by: Jack Pham <jackp@codeaurora.org>