aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/display/intel_lspcon.c
diff options
context:
space:
mode:
authorMaxime Ripard <[email protected]>2023-11-15 09:45:19 +0000
committerMaxime Ripard <[email protected]>2023-11-15 09:56:44 +0000
commit3bf3e21c15d4386a5f15118ec39bbc1b67ea5759 (patch)
treea8880bb7b152d913ebd86e7cd858600dbe22ed38 /drivers/gpu/drm/i915/display/intel_lspcon.c
parentdrm/virtio: Fix return value for VIRTGPU_CONTEXT_PARAM_DEBUG_NAME (diff)
parentLinux 6.7-rc1 (diff)
downloadkernel-3bf3e21c15d4386a5f15118ec39bbc1b67ea5759.tar.gz
kernel-3bf3e21c15d4386a5f15118ec39bbc1b67ea5759.zip
Merge drm/drm-next into drm-misc-next
Let's kickstart the v6.8 release cycle. Signed-off-by: Maxime Ripard <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/i915/display/intel_lspcon.c')
-rw-r--r--drivers/gpu/drm/i915/display/intel_lspcon.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/display/intel_lspcon.c b/drivers/gpu/drm/i915/display/intel_lspcon.c
index 152a22a8ffd2..1d048fa98561 100644
--- a/drivers/gpu/drm/i915/display/intel_lspcon.c
+++ b/drivers/gpu/drm/i915/display/intel_lspcon.c
@@ -153,6 +153,18 @@ static enum drm_lspcon_mode lspcon_get_current_mode(struct intel_lspcon *lspcon)
return current_mode;
}
+static int lspcon_get_mode_settle_timeout(struct intel_lspcon *lspcon)
+{
+ /*
+ * On some CometLake-based device designs the Parade PS175 takes more
+ * than 400ms to settle in PCON mode. 100 reboot trials on one device
+ * resulted in a median settle time of 440ms and a maximum of 444ms.
+ * Even after increasing the timeout to 500ms, 2% of devices still had
+ * this error. So this sets the timeout to 800ms.
+ */
+ return lspcon->vendor == LSPCON_VENDOR_PARADE ? 800 : 400;
+}
+
static enum drm_lspcon_mode lspcon_wait_mode(struct intel_lspcon *lspcon,
enum drm_lspcon_mode mode)
{
@@ -167,7 +179,8 @@ static enum drm_lspcon_mode lspcon_wait_mode(struct intel_lspcon *lspcon,
drm_dbg_kms(&i915->drm, "Waiting for LSPCON mode %s to settle\n",
lspcon_mode_name(mode));
- wait_for((current_mode = lspcon_get_current_mode(lspcon)) == mode, 400);
+ wait_for((current_mode = lspcon_get_current_mode(lspcon)) == mode,
+ lspcon_get_mode_settle_timeout(lspcon));
if (current_mode != mode)
drm_err(&i915->drm, "LSPCON mode hasn't settled\n");