aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoman Li <Roman.Li@amd.com>2018-10-09 13:50:09 -0400
committerAlex Deucher <alexander.deucher@amd.com>2018-10-10 15:47:04 -0400
commitd567cc55c0a9bd2744d5f32e3090e55f9e0c0a40 (patch)
tree94699ce980f30ac97d4dbf19c639a1406b904b26
parent71195ba670bc6070b5db406c4fc12c69efb9f7e4 (diff)
drm/amd/display: Fix warning storm on Raven2
[Why] Wrong index for pstate debug test register [How] Add correct index value for dcn1_01 in hubbub1_construct() Signed-off-by: Hersen Wu <hersenxs.wu@amd.com> Signed-off-by: Roman Li <Roman.Li@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
-rw-r--r--drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hubbub.c43
1 files changed, 41 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hubbub.c b/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hubbub.c
index 69345ce688c6..4254e7e1a509 100644
--- a/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hubbub.c
+++ b/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hubbub.c
@@ -133,7 +133,43 @@ bool hubbub1_verify_allow_pstate_change_high(
133 forced_pstate_allow = false; 133 forced_pstate_allow = false;
134 } 134 }
135 135
136 /* RV1: 136 /* RV2:
137 * dchubbubdebugind, at: 0xB
138 * description
139 * 0: Pipe0 Plane0 Allow Pstate Change
140 * 1: Pipe0 Plane1 Allow Pstate Change
141 * 2: Pipe0 Cursor0 Allow Pstate Change
142 * 3: Pipe0 Cursor1 Allow Pstate Change
143 * 4: Pipe1 Plane0 Allow Pstate Change
144 * 5: Pipe1 Plane1 Allow Pstate Change
145 * 6: Pipe1 Cursor0 Allow Pstate Change
146 * 7: Pipe1 Cursor1 Allow Pstate Change
147 * 8: Pipe2 Plane0 Allow Pstate Change
148 * 9: Pipe2 Plane1 Allow Pstate Change
149 * 10: Pipe2 Cursor0 Allow Pstate Change
150 * 11: Pipe2 Cursor1 Allow Pstate Change
151 * 12: Pipe3 Plane0 Allow Pstate Change
152 * 13: Pipe3 Plane1 Allow Pstate Change
153 * 14: Pipe3 Cursor0 Allow Pstate Change
154 * 15: Pipe3 Cursor1 Allow Pstate Change
155 * 16: Pipe4 Plane0 Allow Pstate Change
156 * 17: Pipe4 Plane1 Allow Pstate Change
157 * 18: Pipe4 Cursor0 Allow Pstate Change
158 * 19: Pipe4 Cursor1 Allow Pstate Change
159 * 20: Pipe5 Plane0 Allow Pstate Change
160 * 21: Pipe5 Plane1 Allow Pstate Change
161 * 22: Pipe5 Cursor0 Allow Pstate Change
162 * 23: Pipe5 Cursor1 Allow Pstate Change
163 * 24: Pipe6 Plane0 Allow Pstate Change
164 * 25: Pipe6 Plane1 Allow Pstate Change
165 * 26: Pipe6 Cursor0 Allow Pstate Change
166 * 27: Pipe6 Cursor1 Allow Pstate Change
167 * 28: WB0 Allow Pstate Change
168 * 29: WB1 Allow Pstate Change
169 * 30: Arbiter's allow_pstate_change
170 * 31: SOC pstate change request"
171 *
172 * RV1:
137 * dchubbubdebugind, at: 0x7 173 * dchubbubdebugind, at: 0x7
138 * description "3-0: Pipe0 cursor0 QOS 174 * description "3-0: Pipe0 cursor0 QOS
139 * 7-4: Pipe1 cursor0 QOS 175 * 7-4: Pipe1 cursor0 QOS
@@ -157,7 +193,6 @@ bool hubbub1_verify_allow_pstate_change_high(
157 * 31: SOC pstate change request 193 * 31: SOC pstate change request
158 */ 194 */
159 195
160
161 REG_WRITE(DCHUBBUB_TEST_DEBUG_INDEX, hubbub->debug_test_index_pstate); 196 REG_WRITE(DCHUBBUB_TEST_DEBUG_INDEX, hubbub->debug_test_index_pstate);
162 197
163 for (i = 0; i < pstate_wait_timeout_us; i++) { 198 for (i = 0; i < pstate_wait_timeout_us; i++) {
@@ -819,5 +854,9 @@ void hubbub1_construct(struct hubbub *hubbub,
819 hubbub->masks = hubbub_mask; 854 hubbub->masks = hubbub_mask;
820 855
821 hubbub->debug_test_index_pstate = 0x7; 856 hubbub->debug_test_index_pstate = 0x7;
857#if defined(CONFIG_DRM_AMD_DC_DCN1_01)
858 if (ctx->dce_version == DCN_VERSION_1_01)
859 hubbub->debug_test_index_pstate = 0xB;
860#endif
822} 861}
823 862