aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/files/0577-drm-amd-dal-Add-unit-mhz-to-clock-members-in-bw-cals.patch
blob: f8a658f7f052e3bd56cc06808f43531a1c8f7659 (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
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
From 95237b75776c9c5c7c1a9c5afa6f230a345d1bd0 Mon Sep 17 00:00:00 2001
From: Yongqiang Sun <yongqiang.sun@amd.com>
Date: Thu, 3 Dec 2015 17:28:13 -0500
Subject: [PATCH 0577/1110] drm/amd/dal: Add unit mhz to clock members in bw
 cals.

Signed-off-by: Yongqiang Sun <yongqiang.sun@amd.com>
Signed-off-by: Harry Wentland <harry.wentland@amd.com>
Acked-by: Harry Wentland <harry.wentland@amd.com>
---
 drivers/gpu/drm/amd/dal/dc/calcs/bandwidth_calcs.c | 129 +++++++++++----------
 drivers/gpu/drm/amd/dal/dc/core/dc.c               |  16 +--
 drivers/gpu/drm/amd/dal/dc/inc/bandwidth_calcs.h   |  16 +--
 3 files changed, 81 insertions(+), 80 deletions(-)

diff --git a/drivers/gpu/drm/amd/dal/dc/calcs/bandwidth_calcs.c b/drivers/gpu/drm/amd/dal/dc/calcs/bandwidth_calcs.c
index 742c4ec..e9fc75f 100644
--- a/drivers/gpu/drm/amd/dal/dc/calcs/bandwidth_calcs.c
+++ b/drivers/gpu/drm/amd/dal/dc/calcs/bandwidth_calcs.c
@@ -114,12 +114,12 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 	enum bw_defines mode_check;
 	uint32_t y_clk_level;
 	uint32_t sclk_level;
-	yclk[high] = vbios->high_yclk;
-	yclk[mid] = vbios->high_yclk;
-	yclk[low] = vbios->low_yclk;
-	sclk[high] = vbios->high_sclk;
-	sclk[mid] = vbios->mid_sclk;
-	sclk[low] = vbios->low_sclk;
+	yclk[high] = vbios->high_yclk_mhz;
+	yclk[mid] = vbios->high_yclk_mhz;
+	yclk[low] = vbios->low_yclk_mhz;
+	sclk[high] = vbios->high_sclk_mhz;
+	sclk[mid] = vbios->mid_sclk_mhz;
+	sclk[low] = vbios->low_sclk_mhz;
 	if (mode_data->d0_underlay_mode == ul_none) {
 		d0_underlay_enable = false;
 	} else {
@@ -2060,11 +2060,11 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 	if (gtn(results->blackout_duration_margin[high][high], int_to_fixed(0))
 		&& ltn(
 			results->dispclk_required_for_blackout_duration[high][high],
-			vbios->high_voltage_max_dispclk)) {
+			vbios->high_voltage_max_dispclk_mhz)) {
 		results->cpup_state_change_enable = true;
 		if (ltn(
 			results->dispclk_required_for_blackout_recovery[high][high],
-			vbios->high_voltage_max_dispclk)) {
+			vbios->high_voltage_max_dispclk_mhz)) {
 			results->cpuc_state_change_enable = true;
 		} else {
 			results->cpuc_state_change_enable = false;
@@ -2203,7 +2203,7 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 	if (gtn(results->dram_speed_change_margin[high][high], int_to_fixed(0))
 		&& ltn(
 			results->dispclk_required_for_dram_speed_change[high][high],
-			vbios->high_voltage_max_dispclk)) {
+			vbios->high_voltage_max_dispclk_mhz)) {
 		results->nbp_state_change_enable = true;
 	} else {
 		results->nbp_state_change_enable = false;
@@ -2260,7 +2260,7 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 		y_clk_level = high;
 		results->dram_bandwidth = mul(
 			bw_div(
-				mul(vbios->high_yclk,
+				mul(vbios->high_yclk_mhz,
 					vbios->dram_channel_width_in_bits),
 				int_to_fixed(8)),
 			vbios->number_of_dram_channels);
@@ -2274,7 +2274,7 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 		y_clk_level = high;
 		results->dram_bandwidth = mul(
 			bw_div(
-				mul(vbios->high_yclk,
+				mul(vbios->high_yclk_mhz,
 					vbios->dram_channel_width_in_bits),
 				int_to_fixed(8)),
 			vbios->number_of_dram_channels);
@@ -2288,7 +2288,7 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 				int_to_fixed(1000)),
 			mul(
 				bw_div(
-					mul(vbios->low_yclk,
+					mul(vbios->low_yclk_mhz,
 						vbios->dram_channel_width_in_bits),
 					int_to_fixed(8)),
 				vbios->number_of_dram_channels))
@@ -2298,28 +2298,28 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 					int_to_fixed(0))
 					&& ltn(
 						results->dispclk_required_for_blackout_duration[low][high],
-						vbios->high_voltage_max_dispclk)))
+						vbios->high_voltage_max_dispclk_mhz)))
 			&& (results->cpuc_state_change_enable == false
 				|| (gtn(
 					results->blackout_duration_margin[low][high],
 					int_to_fixed(0))
 					&& ltn(
 						results->dispclk_required_for_blackout_duration[low][high],
-						vbios->high_voltage_max_dispclk)
+						vbios->high_voltage_max_dispclk_mhz)
 					&& ltn(
 						results->dispclk_required_for_blackout_recovery[low][high],
-						vbios->high_voltage_max_dispclk)))
+						vbios->high_voltage_max_dispclk_mhz)))
 			&& gtn(results->dram_speed_change_margin[low][high],
 				int_to_fixed(0))
 			&& ltn(
 				results->dispclk_required_for_dram_speed_change[low][high],
-				vbios->high_voltage_max_dispclk)) {
+				vbios->high_voltage_max_dispclk_mhz)) {
 			yclk_message = def_low;
 			y_clk_level = low;
 			results->dram_bandwidth =
 				mul(
 					bw_div(
-						mul(vbios->low_yclk,
+						mul(vbios->low_yclk_mhz,
 							vbios->dram_channel_width_in_bits),
 						int_to_fixed(8)),
 					vbios->number_of_dram_channels);
@@ -2328,7 +2328,7 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 				int_to_fixed(1000)),
 			mul(
 				bw_div(
-					mul(vbios->high_yclk,
+					mul(vbios->high_yclk_mhz,
 						vbios->dram_channel_width_in_bits),
 					int_to_fixed(8)),
 				vbios->number_of_dram_channels))) {
@@ -2337,7 +2337,7 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 			results->dram_bandwidth =
 				mul(
 					bw_div(
-						mul(vbios->high_yclk,
+						mul(vbios->high_yclk_mhz,
 							vbios->dram_channel_width_in_bits),
 						int_to_fixed(8)),
 					vbios->number_of_dram_channels);
@@ -2347,7 +2347,7 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 			results->dram_bandwidth =
 				mul(
 					bw_div(
-						mul(vbios->high_yclk,
+						mul(vbios->high_yclk_mhz,
 							vbios->dram_channel_width_in_bits),
 						int_to_fixed(8)),
 					vbios->number_of_dram_channels);
@@ -2377,61 +2377,61 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 	} else {
 		results->required_sclk = bw_max(results->dmif_required_sclk,
 			results->mcifwr_required_sclk);
-		if (ltn(results->required_sclk, vbios->low_sclk)
+		if (ltn(results->required_sclk, vbios->low_sclk_mhz)
 			&& (results->cpup_state_change_enable == false
 				|| (gtn(
 					results->blackout_duration_margin[y_clk_level][low],
 					int_to_fixed(0))
 					&& ltn(
 						results->dispclk_required_for_blackout_duration[y_clk_level][low],
-						vbios->high_voltage_max_dispclk)))
+						vbios->high_voltage_max_dispclk_mhz)))
 			&& (results->cpuc_state_change_enable == false
 				|| (gtn(
 					results->blackout_duration_margin[y_clk_level][low],
 					int_to_fixed(0))
 					&& ltn(
 						results->dispclk_required_for_blackout_duration[y_clk_level][low],
-						vbios->high_voltage_max_dispclk)
+						vbios->high_voltage_max_dispclk_mhz)
 					&& ltn(
 						results->dispclk_required_for_blackout_recovery[y_clk_level][low],
-						vbios->high_voltage_max_dispclk)))
+						vbios->high_voltage_max_dispclk_mhz)))
 			&& (results->nbp_state_change_enable == false
 				|| (gtn(
 					results->dram_speed_change_margin[y_clk_level][low],
 					int_to_fixed(0))
 					&& leq(
 						results->dispclk_required_for_dram_speed_change[y_clk_level][low],
-						vbios->high_voltage_max_dispclk)))) {
+						vbios->high_voltage_max_dispclk_mhz)))) {
 			sclk_message = def_low;
 			sclk_level = low;
-		} else if (ltn(results->required_sclk, vbios->mid_sclk)
+		} else if (ltn(results->required_sclk, vbios->mid_sclk_mhz)
 			&& (results->cpup_state_change_enable == false
 				|| (gtn(
 					results->blackout_duration_margin[y_clk_level][mid],
 					int_to_fixed(0))
 					&& ltn(
 						results->dispclk_required_for_blackout_duration[y_clk_level][mid],
-						vbios->high_voltage_max_dispclk)))
+						vbios->high_voltage_max_dispclk_mhz)))
 			&& (results->cpuc_state_change_enable == false
 				|| (gtn(
 					results->blackout_duration_margin[y_clk_level][mid],
 					int_to_fixed(0))
 					&& ltn(
 						results->dispclk_required_for_blackout_duration[y_clk_level][mid],
-						vbios->high_voltage_max_dispclk)
+						vbios->high_voltage_max_dispclk_mhz)
 					&& ltn(
 						results->dispclk_required_for_blackout_recovery[y_clk_level][mid],
-						vbios->high_voltage_max_dispclk)))
+						vbios->high_voltage_max_dispclk_mhz)))
 			&& (results->nbp_state_change_enable == false
 				|| (gtn(
 					results->dram_speed_change_margin[y_clk_level][mid],
 					int_to_fixed(0))
 					&& leq(
 						results->dispclk_required_for_dram_speed_change[y_clk_level][mid],
-						vbios->high_voltage_max_dispclk)))) {
+						vbios->high_voltage_max_dispclk_mhz)))) {
 			sclk_message = def_mid;
 			sclk_level = mid;
-		} else if (ltn(results->required_sclk, vbios->high_sclk)) {
+		} else if (ltn(results->required_sclk, vbios->high_sclk_mhz)) {
 			sclk_message = def_high;
 			sclk_level = high;
 		} else {
@@ -2620,13 +2620,13 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 	}
 	if (ltn(
 		results->total_dispclk_required_with_ramping_with_request_bandwidth,
-		vbios->high_voltage_max_dispclk)) {
+		vbios->high_voltage_max_dispclk_mhz)) {
 		results->dispclk =
 			results->total_dispclk_required_with_ramping_with_request_bandwidth;
 	} else if (ltn(
 		results->total_dispclk_required_without_ramping_with_request_bandwidth,
-		vbios->high_voltage_max_dispclk)) {
-		results->dispclk = vbios->high_voltage_max_dispclk;
+		vbios->high_voltage_max_dispclk_mhz)) {
+		results->dispclk = vbios->high_voltage_max_dispclk_mhz;
 	} else {
 		results->dispclk =
 			results->total_dispclk_required_without_ramping_with_request_bandwidth;
@@ -2640,20 +2640,20 @@ static void calculate_bandwidth(const struct bw_calcs_input_dceip *dceip,
 		mode_background_color = def_notok_color;
 		mode_font_color = def_vb_black;
 	} else if (yclk_message == def_low && sclk_message == def_low
-		&& ltn(results->dispclk, vbios->low_voltage_max_dispclk)) {
+		&& ltn(results->dispclk, vbios->low_voltage_max_dispclk_mhz)) {
 		voltage = def_low;
 		mode_background_color = def_low_color;
 		mode_font_color = def_vb_black;
 	} else if (yclk_message == def_low
 		&& (sclk_message == def_low || sclk_message == def_mid)
-		&& ltn(results->dispclk, vbios->mid_voltage_max_dispclk)) {
+		&& ltn(results->dispclk, vbios->mid_voltage_max_dispclk_mhz)) {
 		voltage = def_mid;
 		mode_background_color = def_mid_color;
 		mode_font_color = def_vb_black;
 	} else if ((yclk_message == def_low || yclk_message == def_high)
 		&& (sclk_message == def_low || sclk_message == def_mid
 			|| sclk_message == def_high)
-		&& leq(results->dispclk, vbios->high_voltage_max_dispclk)) {
+		&& leq(results->dispclk, vbios->high_voltage_max_dispclk_mhz)) {
 		if (results->nbp_state_change_enable == true) {
 			voltage = def_high;
 			mode_background_color = def_high_color;
@@ -3161,14 +3161,14 @@ void bw_calcs_init(struct bw_calcs_input_dceip *bw_dceip,
 	vbios.number_of_dram_channels = int_to_fixed(2);
 	vbios.dram_channel_width_in_bits = int_to_fixed(64);
 	vbios.number_of_dram_banks = int_to_fixed(8);
-	vbios.high_yclk = int_to_fixed(1600);
-	vbios.low_yclk = frc_to_fixed(66666, 100);
-	vbios.low_sclk = int_to_fixed(200);
-	vbios.mid_sclk = int_to_fixed(300);
-	vbios.high_sclk = frc_to_fixed(62609, 100);
-	vbios.low_voltage_max_dispclk = int_to_fixed(352);
-	vbios.mid_voltage_max_dispclk = int_to_fixed(467);
-	vbios.high_voltage_max_dispclk = int_to_fixed(643);
+	vbios.high_yclk_mhz = int_to_fixed(1600);
+	vbios.low_yclk_mhz = frc_to_fixed(66666, 100);
+	vbios.low_sclk_mhz = int_to_fixed(200);
+	vbios.mid_sclk_mhz = int_to_fixed(300);
+	vbios.high_sclk_mhz = frc_to_fixed(62609, 100);
+	vbios.low_voltage_max_dispclk_mhz = int_to_fixed(352);
+	vbios.mid_voltage_max_dispclk_mhz = int_to_fixed(467);
+	vbios.high_voltage_max_dispclk_mhz = int_to_fixed(643);
 	vbios.data_return_bus_width = int_to_fixed(32);
 	vbios.trc = int_to_fixed(50);
 	vbios.dmifmc_urgent_latency = int_to_fixed(4);
@@ -3366,16 +3366,16 @@ bool bw_calcs(struct dc_context *ctx, const struct bw_calcs_input_dceip *dceip,
 	}
 
 	if (bw_data_internal->number_of_displays != 0) {
-		struct bw_fixed high_sclk = vbios->high_sclk;
-		struct bw_fixed low_sclk = vbios->low_sclk;
-		struct bw_fixed high_yclk = vbios->high_yclk;
-		struct bw_fixed low_yclk = vbios->low_yclk;
+		struct bw_fixed high_sclk = vbios->high_sclk_mhz;
+		struct bw_fixed low_sclk = vbios->low_sclk_mhz;
+		struct bw_fixed high_yclk = vbios->high_yclk_mhz;
+		struct bw_fixed low_yclk = vbios->low_yclk_mhz;
 
-		((struct bw_calcs_input_vbios *)vbios)->low_yclk = low_yclk;
-		((struct bw_calcs_input_vbios *)vbios)->high_yclk = low_yclk;
-		((struct bw_calcs_input_vbios *)vbios)->low_sclk = low_sclk;
-		((struct bw_calcs_input_vbios *)vbios)->mid_sclk = low_sclk;
-		((struct bw_calcs_input_vbios *)vbios)->high_sclk = low_sclk;
+		((struct bw_calcs_input_vbios *)vbios)->low_yclk_mhz = low_yclk;
+		((struct bw_calcs_input_vbios *)vbios)->high_yclk_mhz = low_yclk;
+		((struct bw_calcs_input_vbios *)vbios)->low_sclk_mhz = low_sclk;
+		((struct bw_calcs_input_vbios *)vbios)->mid_sclk_mhz = low_sclk;
+		((struct bw_calcs_input_vbios *)vbios)->high_sclk_mhz = low_sclk;
 		calculate_bandwidth(dceip, vbios, bw_data_internal,
 							bw_results_internal);
 
@@ -3410,11 +3410,11 @@ bool bw_calcs(struct dc_context *ctx, const struct bw_calcs_input_dceip *dceip,
 			mul(bw_results_internal->urgent_watermark[6],
 					int_to_fixed(1000)).value >> 24;
 
-		((struct bw_calcs_input_vbios *)vbios)->low_yclk = high_yclk;
-		((struct bw_calcs_input_vbios *)vbios)->high_yclk = high_yclk;
-		((struct bw_calcs_input_vbios *)vbios)->low_sclk = high_sclk;
-		((struct bw_calcs_input_vbios *)vbios)->mid_sclk = high_sclk;
-		((struct bw_calcs_input_vbios *)vbios)->high_sclk = high_sclk;
+		((struct bw_calcs_input_vbios *)vbios)->low_yclk_mhz = high_yclk;
+		((struct bw_calcs_input_vbios *)vbios)->high_yclk_mhz = high_yclk;
+		((struct bw_calcs_input_vbios *)vbios)->low_sclk_mhz = high_sclk;
+		((struct bw_calcs_input_vbios *)vbios)->mid_sclk_mhz = high_sclk;
+		((struct bw_calcs_input_vbios *)vbios)->high_sclk_mhz = high_sclk;
 
 		calculate_bandwidth(dceip, vbios, bw_data_internal,
 							bw_results_internal);
@@ -3473,11 +3473,12 @@ bool bw_calcs(struct dc_context *ctx, const struct bw_calcs_input_dceip *dceip,
 		calcs_output->required_yclk =
 				mul(high_yclk, int_to_fixed(1000)).value >> 24;
 
-		((struct bw_calcs_input_vbios *)vbios)->low_yclk = low_yclk;
-		((struct bw_calcs_input_vbios *)vbios)->high_yclk = high_yclk;
-		((struct bw_calcs_input_vbios *)vbios)->low_sclk = low_sclk;
-		((struct bw_calcs_input_vbios *)vbios)->mid_sclk = high_sclk;
-		((struct bw_calcs_input_vbios *)vbios)->high_sclk = high_sclk;
+		((struct bw_calcs_input_vbios *)vbios)->low_yclk_mhz = low_yclk;
+		((struct bw_calcs_input_vbios *)vbios)->high_yclk_mhz =
+								high_yclk;
+		((struct bw_calcs_input_vbios *)vbios)->low_sclk_mhz = low_sclk;
+		((struct bw_calcs_input_vbios *)vbios)->mid_sclk_mhz = high_sclk;
+		((struct bw_calcs_input_vbios *)vbios)->high_sclk_mhz = high_sclk;
 	} else {
 		calcs_output->nbp_state_change_enable = true;
 		calcs_output->cpuc_state_change_enable = true;
diff --git a/drivers/gpu/drm/amd/dal/dc/core/dc.c b/drivers/gpu/drm/amd/dal/dc/core/dc.c
index 599bf2f..50505f4 100644
--- a/drivers/gpu/drm/amd/dal/dc/core/dc.c
+++ b/drivers/gpu/drm/amd/dal/dc/core/dc.c
@@ -234,11 +234,11 @@ static void bw_calcs_data_update_from_pplib(struct dc *dc)
 			DC_PP_CLOCK_TYPE_ENGINE_CLK,
 			&clks);
 	/* convert all the clock fro kHz to fix point mHz */
-	dc->bw_vbios.high_sclk = frc_to_fixed(
+	dc->bw_vbios.high_sclk_mhz = frc_to_fixed(
 			clks.clocks_in_khz[clks.num_levels-1], 1000);
-	dc->bw_vbios.mid_sclk  = frc_to_fixed(
+	dc->bw_vbios.mid_sclk_mhz  = frc_to_fixed(
 			clks.clocks_in_khz[clks.num_levels>>1], 1000);
-	dc->bw_vbios.low_sclk  = frc_to_fixed(
+	dc->bw_vbios.low_sclk_mhz  = frc_to_fixed(
 			clks.clocks_in_khz[0], 1000);
 
 	/*do display clock*/
@@ -247,11 +247,11 @@ static void bw_calcs_data_update_from_pplib(struct dc *dc)
 			DC_PP_CLOCK_TYPE_DISPLAY_CLK,
 			&clks);
 
-	dc->bw_vbios.high_voltage_max_dispclk = frc_to_fixed(
+	dc->bw_vbios.high_voltage_max_dispclk_mhz = frc_to_fixed(
 			clks.clocks_in_khz[clks.num_levels-1], 1000);
-	dc->bw_vbios.mid_voltage_max_dispclk  = frc_to_fixed(
+	dc->bw_vbios.mid_voltage_max_dispclk_mhz  = frc_to_fixed(
 			clks.clocks_in_khz[clks.num_levels>>1], 1000);
-	dc->bw_vbios.low_voltage_max_dispclk  = frc_to_fixed(
+	dc->bw_vbios.low_voltage_max_dispclk_mhz  = frc_to_fixed(
 			clks.clocks_in_khz[0], 1000);
 
 	/*do memory clock*/
@@ -260,9 +260,9 @@ static void bw_calcs_data_update_from_pplib(struct dc *dc)
 			DC_PP_CLOCK_TYPE_MEMORY_CLK,
 			&clks);
 
-	dc->bw_vbios.low_yclk = frc_to_fixed(
+	dc->bw_vbios.low_yclk_mhz = frc_to_fixed(
 			clks.clocks_in_khz[0], 1000);
-	dc->bw_vbios.high_yclk = frc_to_fixed(
+	dc->bw_vbios.high_yclk_mhz = frc_to_fixed(
 			clks.clocks_in_khz[clks.num_levels-1], 1000);
 	return;
 
diff --git a/drivers/gpu/drm/amd/dal/dc/inc/bandwidth_calcs.h b/drivers/gpu/drm/amd/dal/dc/inc/bandwidth_calcs.h
index a304ce8..6422298 100644
--- a/drivers/gpu/drm/amd/dal/dc/inc/bandwidth_calcs.h
+++ b/drivers/gpu/drm/amd/dal/dc/inc/bandwidth_calcs.h
@@ -123,16 +123,16 @@ struct bw_calcs_input_vbios {
 	struct bw_fixed dram_channel_width_in_bits;
 	struct bw_fixed number_of_dram_channels;
 	struct bw_fixed number_of_dram_banks;
-	struct bw_fixed high_yclk;
+	struct bw_fixed high_yclk_mhz;
 	struct bw_fixed high_dram_bandwidth_per_channel;
-	struct bw_fixed low_yclk;
+	struct bw_fixed low_yclk_mhz;
 	struct bw_fixed low_dram_bandwidth_per_channel;
-	struct bw_fixed low_sclk;
-	struct bw_fixed mid_sclk;
-	struct bw_fixed high_sclk;
-	struct bw_fixed low_voltage_max_dispclk;
-	struct bw_fixed mid_voltage_max_dispclk;
-	struct bw_fixed high_voltage_max_dispclk;
+	struct bw_fixed low_sclk_mhz;
+	struct bw_fixed mid_sclk_mhz;
+	struct bw_fixed high_sclk_mhz;
+	struct bw_fixed low_voltage_max_dispclk_mhz;
+	struct bw_fixed mid_voltage_max_dispclk_mhz;
+	struct bw_fixed high_voltage_max_dispclk_mhz;
 	struct bw_fixed data_return_bus_width;
 	struct bw_fixed trc;
 	struct bw_fixed dmifmc_urgent_latency;
-- 
2.7.4