Skip to content

Commit 3ba2a0b

Browse files
Ilya Bakoulinalexdeucher
authored andcommitted
drm/amd/display: Clear OPTC mem select on disable
[Why] Not clearing the memory select bits prior to OPTC disable can cause DSC corruption issues when attempting to reuse a memory instance for another OPTC that enables ODM. [How] Clear the memory select bits prior to disabling an OPTC. Cc: Mario Limonciello <mario.limonciello@amd.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org Reviewed-by: Charlene Liu <charlene.liu@amd.com> Acked-by: Alex Hung <alex.hung@amd.com> Signed-off-by: Ilya Bakoulin <ilya.bakoulin@amd.com> Tested-by: Daniel Wheeler <daniel.wheeler@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
1 parent 4b56f7d commit 3ba2a0b

2 files changed

Lines changed: 6 additions & 0 deletions

File tree

drivers/gpu/drm/amd/display/dc/optc/dcn32/dcn32_optc.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,9 @@ static bool optc32_disable_crtc(struct timing_generator *optc)
173173
OPTC_SEG3_SRC_SEL, 0xf,
174174
OPTC_NUM_OF_INPUT_SEGMENT, 0);
175175

176+
REG_UPDATE(OPTC_MEMORY_CONFIG,
177+
OPTC_MEM_SEL, 0);
178+
176179
/* disable otg request until end of the first line
177180
* in the vertical blank region
178181
*/

drivers/gpu/drm/amd/display/dc/optc/dcn35/dcn35_optc.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,9 @@ static bool optc35_disable_crtc(struct timing_generator *optc)
145145
OPTC_SEG3_SRC_SEL, 0xf,
146146
OPTC_NUM_OF_INPUT_SEGMENT, 0);
147147

148+
REG_UPDATE(OPTC_MEMORY_CONFIG,
149+
OPTC_MEM_SEL, 0);
150+
148151
/* disable otg request until end of the first line
149152
* in the vertical blank region
150153
*/

0 commit comments

Comments
 (0)