Skip to content

Commit 18aefea

Browse files
Rodrigo Siqueiraalexdeucher
authored andcommitted
drm/amd/display: Fix compilation errors on DCN314
We have some compilation errors in some DML files from DCN314 that we never noticed because we were not compiling some of the DML files. This commit fixes those syntax errors before we enable the compilation. Cc: Roman Li <[email protected]> Tested-by: Daniel Wheeler <[email protected]> Signed-off-by: Rodrigo Siqueira <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
1 parent f9c1820 commit 18aefea

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

drivers/gpu/drm/amd/display/dc/dml/dcn314/display_mode_vba_314.c

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161
// fudge factor for min dcfclk calclation
6262
#define __DML_MIN_DCFCLK_FACTOR__ 1.15
6363

64-
struct {
64+
typedef struct {
6565
double DPPCLK;
6666
double DISPCLK;
6767
double PixelClock;
@@ -1599,7 +1599,7 @@ static void CalculateDCCConfiguration(
15991599
int segment_order_vert_contiguous_luma;
16001600
int segment_order_vert_contiguous_chroma;
16011601

1602-
enum {
1602+
typedef enum {
16031603
REQ_256Bytes, REQ_128BytesNonContiguous, REQ_128BytesContiguous, REQ_NA
16041604
} RequestType;
16051605
RequestType RequestLuma;
@@ -7157,12 +7157,13 @@ static double CalculateExtraLatencyBytes(
71577157
HostVMDynamicLevels = dml_max(0, (int) HostVMMaxNonCachedPageTableLevels - 1);
71587158
else
71597159
HostVMDynamicLevels = dml_max(0, (int) HostVMMaxNonCachedPageTableLevels - 2);
7160-
else
7160+
} else {
71617161
HostVMDynamicLevels = 0;
7162+
}
71627163

71637164
ret = ReorderingBytes + (TotalNumberOfActiveDPP * PixelChunkSizeInKByte + TotalNumberOfDCCActiveDPP * MetaChunkSize) * 1024.0;
71647165

7165-
if (GPUVMEnable == true)
7166+
if (GPUVMEnable == true) {
71667167
for (k = 0; k < NumberOfActivePlanes; ++k)
71677168
ret = ret + NumberOfDPP[k] * dpte_group_bytes[k] * (1 + 8 * HostVMDynamicLevels) * HostVMInefficiencyFactor;
71687169
}

0 commit comments

Comments
 (0)