summarylogtreecommitdiffstats
path: root/0002-drm-i915-edp-Only-use-the-alternate-fixed-mode-if-it.patch
blob: 9de06fe15da3d3406ea0d0065b338f23a7a068d0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
From 1ab88f114ddb0f614118c330196af3024f88630c Mon Sep 17 00:00:00 2001
Message-Id: <1ab88f114ddb0f614118c330196af3024f88630c.1523790169.git.jan.steffens@gmail.com>
In-Reply-To: <3a7745f6fdd71aa34dae33c3edc586363d9ece9e.1523790169.git.jan.steffens@gmail.com>
References: <3a7745f6fdd71aa34dae33c3edc586363d9ece9e.1523790169.git.jan.steffens@gmail.com>
From: Jim Bride <jim.bride@linux.intel.com>
Date: Mon, 6 Nov 2017 13:38:57 -0800
Subject: [PATCH 2/3] drm/i915/edp: Only use the alternate fixed mode if it's
 asked for

In commit dc911f5bd8aa ("drm/i915/edp: Allow alternate fixed mode for
eDP if available."), the patch allows for the use of an alternate fixed
mode if it is available, but the patch was not ensuring that the only
time the alternate mode is used is when it is specifically requested.
This patch adds an additional comparison to intel_edp_compare_alt_mode
to ensure that we only use the alternate mode if it is directly
requested.

Fixes: dc911f5bd8aac ("Allow alternate fixed mode for eDP if available.")
Cc: David Weinehall <david.weinehall@linux.intel.com>
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
Signed-off-by: Jim Bride <jim.bride@linux.intel.com>
---
 drivers/gpu/drm/i915/intel_dp.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index a29868cd30c7..b6d07b615b12 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -1597,7 +1597,8 @@ static bool intel_edp_compare_alt_mode(struct drm_display_mode *m1,
 			m1->vdisplay == m2->vdisplay &&
 			m1->vsync_start == m2->vsync_start &&
 			m1->vsync_end == m2->vsync_end &&
-			m1->vtotal == m2->vtotal);
+			m1->vtotal == m2->vtotal &&
+			m1->vrefresh == m2->vrefresh);
 	return bres;
 }
 
-- 
2.17.0