summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/i915/display/intel_tc.c
diff options
context:
space:
mode:
authorImre Deak <imre.deak@intel.com>2023-03-16 15:17:18 +0200
committerImre Deak <imre.deak@intel.com>2023-03-22 20:31:13 +0200
commitc173a91b760844074abcd636eda47d3b2c107a64 (patch)
tree28380c720b125983bcd1e37d57b0b0a9f14f6aa3 /drivers/gpu/drm/i915/display/intel_tc.c
parenta8da6c18b481efbe78618dbba18c2db3241f4fea (diff)
downloadlinux-c173a91b760844074abcd636eda47d3b2c107a64.tar.gz
linux-c173a91b760844074abcd636eda47d3b2c107a64.tar.bz2
linux-c173a91b760844074abcd636eda47d3b2c107a64.zip
drm/i915/tc: Fix TC mode for a legacy port if the PHY is not ready
A legacy TC port can't be switched to TBT mode, even if the PHY initialization wasn't ready yet for some reason, so prevent this. This shouldn't normally happen as the driver waits for the IOM/TCSS PHY initialization during driver loading and system resume. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230316131724.359612-9-imre.deak@intel.com
Diffstat (limited to 'drivers/gpu/drm/i915/display/intel_tc.c')
-rw-r--r--drivers/gpu/drm/i915/display/intel_tc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/display/intel_tc.c b/drivers/gpu/drm/i915/display/intel_tc.c
index e39c8a870df0..f66129494cc4 100644
--- a/drivers/gpu/drm/i915/display/intel_tc.c
+++ b/drivers/gpu/drm/i915/display/intel_tc.c
@@ -482,7 +482,8 @@ static void icl_tc_phy_connect(struct intel_digital_port *dig_port,
u32 live_status_mask;
int max_lanes;
- if (!tc_phy_status_complete(dig_port)) {
+ if (!tc_phy_status_complete(dig_port) &&
+ !drm_WARN_ON(&i915->drm, dig_port->tc_legacy_port)) {
drm_dbg_kms(&i915->drm, "Port %s: PHY not ready\n",
dig_port->tc_port_name);
goto out_set_tbt_alt_mode;