aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/display/intel_bios.c
diff options
context:
space:
mode:
authorUma Shankar <uma.shankar@intel.com>2021-02-11 17:12:09 +0530
committerUma Shankar <uma.shankar@intel.com>2021-02-11 22:29:43 +0530
commitaaab24bb25e9fc4c8f3a1d9a593d3ace2c4af243 (patch)
treee22050b74495eddec84cd7e30faecca83abe6ae6 /drivers/gpu/drm/i915/display/intel_bios.c
parentdrm/i915/display: Add DDR5 and LPDDR5 BW buddy page entries (diff)
downloadlinux-dev-aaab24bb25e9fc4c8f3a1d9a593d3ace2c4af243.tar.xz
linux-dev-aaab24bb25e9fc4c8f3a1d9a593d3ace2c4af243.zip
drm/i915/display: Handle lane polarity for DDI port
Lane Reversal is required for some of the DDI ports. This information is populated in VBT and driver should read the same and set the polarity while enabling the port. This patch handles the same. It helps fix a display blankout issue on DP ports on certain platforms. Signed-off-by: Uma Shankar <uma.shankar@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20210211114209.23866-1-uma.shankar@intel.com
Diffstat (limited to 'drivers/gpu/drm/i915/display/intel_bios.c')
-rw-r--r--drivers/gpu/drm/i915/display/intel_bios.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/display/intel_bios.c b/drivers/gpu/drm/i915/display/intel_bios.c
index 7118530a1c38..dd51413e7f45 100644
--- a/drivers/gpu/drm/i915/display/intel_bios.c
+++ b/drivers/gpu/drm/i915/display/intel_bios.c
@@ -2674,6 +2674,23 @@ intel_bios_is_lspcon_present(const struct drm_i915_private *i915,
return HAS_LSPCON(i915) && child && child->lspcon;
}
+/**
+ * intel_bios_is_lane_reversal_needed - if lane reversal needed on port
+ * @i915: i915 device instance
+ * @port: port to check
+ *
+ * Return true if port requires lane reversal
+ */
+bool
+intel_bios_is_lane_reversal_needed(const struct drm_i915_private *i915,
+ enum port port)
+{
+ const struct child_device_config *child =
+ i915->vbt.ddi_port_info[port].child;
+
+ return child && child->lane_reversal;
+}
+
enum aux_ch intel_bios_port_aux_ch(struct drm_i915_private *dev_priv,
enum port port)
{