Skip to content

Commit 791255c

Browse files
Nicholas Kazlauskasalexdeucher
authored andcommitted
drm/amd/display: Reset DMCUB before HW init
[Why] If the firmware wasn't reset by PSP or HW and is currently running then the firmware will hang or perform underfined behavior when we modify its firmware state underneath it. [How] Reset DMCUB before setting up cache windows and performing HW init. Reviewed-by: Aurabindo Jayamohanan Pillai <[email protected]> Acked-by: Pavle Kotarac <[email protected]> Tested-by: Daniel Wheeler <[email protected]> Signed-off-by: Nicholas Kazlauskas <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
1 parent 7e4d2f3 commit 791255c

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1051,6 +1051,11 @@ static int dm_dmub_hw_init(struct amdgpu_device *adev)
10511051
return 0;
10521052
}
10531053

1054+
/* Reset DMCUB if it was previously running - before we overwrite its memory. */
1055+
status = dmub_srv_hw_reset(dmub_srv);
1056+
if (status != DMUB_STATUS_OK)
1057+
DRM_WARN("Error resetting DMUB HW: %d\n", status);
1058+
10541059
hdr = (const struct dmcub_firmware_header_v1_0 *)dmub_fw->data;
10551060

10561061
fw_inst_const = dmub_fw->data +

0 commit comments

Comments
 (0)