drm/i915: Force a TypeC PHY disconnect during suspend/shutdown
authorImre Deak <imre.deak@intel.com>
Thu, 10 Jun 2021 17:42:23 +0000 (20:42 +0300)
committerImre Deak <imre.deak@intel.com>
Wed, 16 Jun 2021 16:13:43 +0000 (19:13 +0300)
commit151ec347b06a2fb6ecd2922475dca71a7af827a5
tree3c740cb0b943fad7ecb1da0aec6ff7caba317dfa
parent544021e3f2aa3c4c6c5aabc58907e8bab69b3762
drm/i915: Force a TypeC PHY disconnect during suspend/shutdown

Disconnect TypeC PHYs during system suspend and shutdown, even with the
corresponding TypeC sink still plugged to its connector, since leaving
the PHY connected causes havoc at least during system resume in the
presence of an Nvidia card.

Note that this will only make a difference in the TypeC DP alternate
mode, since in Thunderbolt alternate mode the PHY is never owned by the
display engine and there is no notion of PHY ownership in legacy mode
(the display engine being the only possible owner in that mode and the
TypeC subsystem not having anything to do with the port in that case).

Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/3500
Reported-and-tested-by: Chris Chiu <chris.chiu@canonical.com>
Signed-off-by: Imre Deak <imre.deak@intel.com>
Reviewed-by: Uma Shankar <uma.shankar@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20210610174223.605904-1-imre.deak@intel.com
drivers/gpu/drm/i915/display/intel_ddi.c
drivers/gpu/drm/i915/display/intel_tc.c
drivers/gpu/drm/i915/display/intel_tc.h