aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/files/0596-drm-amd-dal-find-proper-connector-in-reset-case.patch
blob: 41c738e607cd29ca946d69fbaa3fe1301d5d2a22 (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
From 52b28a87980253648b092fa584ae9be4e67ecead Mon Sep 17 00:00:00 2001
From: Mykola Lysenko <Mykola.Lysenko@amd.com>
Date: Wed, 9 Dec 2015 20:03:01 +0800
Subject: [PATCH 0596/1110] drm/amd/dal: find proper connector in reset case

Find connector on reset properly, and allow reset mode occur for
MST connector.

It also remove warning messages seen previously

Signed-off-by: Harry Wentland <harry.wentland@amd.com>
Acked-by: Harry Wentland<harry.wentland@amd.com>
---
 drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_types.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_types.c b/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_types.c
index 6dc7ead..9f467eb 100644
--- a/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_types.c
+++ b/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_types.c
@@ -2115,6 +2115,16 @@ int amdgpu_dm_atomic_commit(
 				aconnector = to_amdgpu_connector(connector);
 				break;
 			}
+
+			/*
+			 * this is the case when reset occur, connector is
+			 * removed from new crtc state. We need to update
+			 * connector state anyway. Access it from old_con_state
+			 */
+			if (old_con_state->crtc == crtc) {
+				aconnector = to_amdgpu_connector(connector);
+				break;
+			}
 		}
 
 		/* handles headless hotplug case, updating new_state and
-- 
2.7.4