aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/linux-yocto-4.14.71/1019-drm-amd-display-Rename-dc-resource_validate_ctx-meth.patch
blob: 345648b549c260d69f3c2e2563d72ea98d5a78ee (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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
From 33111183e42f859b9baa23d8f33b573ed7b2eddc Mon Sep 17 00:00:00 2001
From: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>
Date: Mon, 28 Aug 2017 12:04:23 -0400
Subject: [PATCH 1019/4131] drm/amd/display: Rename dc resource_validate_ctx
 methods

Rename dc_resource methods from validate_ctx to state

Change-Id: Ia43f6863b463bc3834e2df27b69f64291194f7d9
Signed-off-by: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
Acked-by: Harry Wentland <Harry.Wentland@amd.com>
---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 +-
 drivers/gpu/drm/amd/display/dc/core/dc.c          | 6 +++---
 drivers/gpu/drm/amd/display/dc/core/dc_resource.c | 8 ++++----
 drivers/gpu/drm/amd/display/dc/dc.h               | 6 +++---
 4 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
index 2ec21fe..feae180 100644
--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
@@ -838,7 +838,7 @@ dm_atomic_state_alloc(struct drm_device *dev)
 
 	atomic_inc(&new_ctx->ref_count);
 
-	dc_resource_validate_ctx_copy_construct_current(dc, new_ctx);
+	dc_resource_state_copy_construct_current(dc, new_ctx);
 
 	state->context = new_ctx;
 
diff --git a/drivers/gpu/drm/amd/display/dc/core/dc.c b/drivers/gpu/drm/amd/display/dc/core/dc.c
index c032f9f..7d43b25 100644
--- a/drivers/gpu/drm/amd/display/dc/core/dc.c
+++ b/drivers/gpu/drm/amd/display/dc/core/dc.c
@@ -1013,7 +1013,7 @@ void dc_release_state(struct dc_state *context)
 	atomic_dec(&context->ref_count);
 
 	if (atomic_read(&context->ref_count) == 0) {
-		dc_resource_validate_ctx_destruct(context);
+		dc_resource_state_destruct(context);
 		dm_free(context);
 	}
 }
@@ -1285,7 +1285,7 @@ void dc_update_planes_and_stream(struct dc *dc,
 
 		atomic_inc(&context->ref_count);
 
-		dc_resource_validate_ctx_copy_construct(
+		dc_resource_state_copy_construct(
 				dc->current_state, context);
 
 		/*remove old surfaces from context */
@@ -1660,7 +1660,7 @@ void dc_set_power_state(
 
 		/* Preserve refcount */
 		ref_count = dc->current_state->ref_count;
-		dc_resource_validate_ctx_destruct(dc->current_state);
+		dc_resource_state_destruct(dc->current_state);
 		memset(dc->current_state, 0,
 				sizeof(*dc->current_state));
 		dc->current_state->ref_count = ref_count;
diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_resource.c b/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
index b5ccbdb..c80650e 100644
--- a/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
+++ b/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
@@ -1707,11 +1707,11 @@ void validate_guaranteed_copy_streams(
 	}
 }
 
-void dc_resource_validate_ctx_copy_construct_current(
+void dc_resource_state_copy_construct_current(
 		const struct dc *dc,
 		struct dc_state *dst_ctx)
 {
-	dc_resource_validate_ctx_copy_construct(dc->current_state, dst_ctx);
+	dc_resource_state_copy_construct(dc->current_state, dst_ctx);
 }
 
 bool dc_validate_global_state(
@@ -2413,7 +2413,7 @@ static void set_vsc_info_packet(
 	/*TODO: stereo 3D support and extend pixel encoding colorimetry*/
 }
 
-void dc_resource_validate_ctx_destruct(struct dc_state *context)
+void dc_resource_state_destruct(struct dc_state *context)
 {
 	int i, j;
 
@@ -2432,7 +2432,7 @@ void dc_resource_validate_ctx_destruct(struct dc_state *context)
  * Copy src_ctx into dst_ctx and retain all surfaces and streams referenced
  * by the src_ctx
  */
-void dc_resource_validate_ctx_copy_construct(
+void dc_resource_state_copy_construct(
 		const struct dc_state *src_ctx,
 		struct dc_state *dst_ctx)
 {
diff --git a/drivers/gpu/drm/amd/display/dc/dc.h b/drivers/gpu/drm/amd/display/dc/dc.h
index 3cbff8c..deb05bb 100644
--- a/drivers/gpu/drm/amd/display/dc/dc.h
+++ b/drivers/gpu/drm/amd/display/dc/dc.h
@@ -695,15 +695,15 @@ bool dc_validate_global_state(
  *   No hardware is programmed for call.  Only validation is done.
  */
 
-void dc_resource_validate_ctx_copy_construct(
+void dc_resource_state_copy_construct(
 		const struct dc_state *src_ctx,
 		struct dc_state *dst_ctx);
 
-void dc_resource_validate_ctx_copy_construct_current(
+void dc_resource_state_copy_construct_current(
 		const struct dc *dc,
 		struct dc_state *dst_ctx);
 
-void dc_resource_validate_ctx_destruct(struct dc_state *context);
+void dc_resource_state_destruct(struct dc_state *context);
 
 /*
  * TODO update to make it about validation sets
-- 
2.7.4