mirror of
https://github.com/torvalds/linux.git
synced 2024-11-11 06:31:49 +00:00
drm/i915: Also check for VGA converter in eDP probe
Unfortunately even the HPD based detection added in commitcfe5bdfb27
("drm/i915: Check HPD live state during eDP probe") fails to detect that the VBT's eDP/DDI-A is a ghost on Asus B360M-A (CFL+CNP). On that board eDP/DDI-A has its HPD asserted despite nothing being actually connected there :( The straps/fuses also indicate that the eDP port is present. So if one boots with a VGA monitor connected the eDP probe will mistake the DP->VGA converter hooked to DDI-E for an eDP panel on DDI-A. As a last resort check what kind of DP device we've detected, and if it looks like a DP->VGA converter then conclude that the eDP port should be ignored. Cc: stable@vger.kernel.org Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/9636 Fixes:cfe5bdfb27
("drm/i915: Check HPD live state during eDP probe") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20231114142333.15799-1-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> (cherry picked from commitfcd479a791
) Signed-off-by: Jani Nikula <jani.nikula@intel.com>
This commit is contained in:
parent
503579448d
commit
f76f83a83c
@ -6037,8 +6037,7 @@ static bool intel_edp_init_connector(struct intel_dp *intel_dp,
|
||||
* (eg. Acer Chromebook C710), so we'll check it only if multiple
|
||||
* ports are attempting to use the same AUX CH, according to VBT.
|
||||
*/
|
||||
if (intel_bios_dp_has_shared_aux_ch(encoder->devdata) &&
|
||||
!intel_digital_port_connected(encoder)) {
|
||||
if (intel_bios_dp_has_shared_aux_ch(encoder->devdata)) {
|
||||
/*
|
||||
* If this fails, presume the DPCD answer came
|
||||
* from some other port using the same AUX CH.
|
||||
@ -6046,10 +6045,27 @@ static bool intel_edp_init_connector(struct intel_dp *intel_dp,
|
||||
* FIXME maybe cleaner to check this before the
|
||||
* DPCD read? Would need sort out the VDD handling...
|
||||
*/
|
||||
drm_info(&dev_priv->drm,
|
||||
"[ENCODER:%d:%s] HPD is down, disabling eDP\n",
|
||||
encoder->base.base.id, encoder->base.name);
|
||||
goto out_vdd_off;
|
||||
if (!intel_digital_port_connected(encoder)) {
|
||||
drm_info(&dev_priv->drm,
|
||||
"[ENCODER:%d:%s] HPD is down, disabling eDP\n",
|
||||
encoder->base.base.id, encoder->base.name);
|
||||
goto out_vdd_off;
|
||||
}
|
||||
|
||||
/*
|
||||
* Unfortunately even the HPD based detection fails on
|
||||
* eg. Asus B360M-A (CFL+CNP), so as a last resort fall
|
||||
* back to checking for a VGA branch device. Only do this
|
||||
* on known affected platforms to minimize false positives.
|
||||
*/
|
||||
if (DISPLAY_VER(dev_priv) == 9 && drm_dp_is_branch(intel_dp->dpcd) &&
|
||||
(intel_dp->dpcd[DP_DOWNSTREAMPORT_PRESENT] & DP_DWN_STRM_PORT_TYPE_MASK) ==
|
||||
DP_DWN_STRM_PORT_TYPE_ANALOG) {
|
||||
drm_info(&dev_priv->drm,
|
||||
"[ENCODER:%d:%s] VGA converter detected, disabling eDP\n",
|
||||
encoder->base.base.id, encoder->base.name);
|
||||
goto out_vdd_off;
|
||||
}
|
||||
}
|
||||
|
||||
mutex_lock(&dev_priv->drm.mode_config.mutex);
|
||||
|
Loading…
Reference in New Issue
Block a user