Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/amd/display: Reset inbox rptr/wptr when resetting DMCUB

[Why]
These logically make sense more to be set after the DMCUB has been
reset rather than when we setup the inbox.

[How]
Move them into the reset callback.

Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
Acked-by: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

authored by

Nicholas Kazlauskas and committed by
Alex Deucher
a7da96fb cc934031

+2 -2
+2 -2
drivers/gpu/drm/amd/display/dmub/src/dmub_dcn20.c
··· 80 80 REG_UPDATE(DMCUB_CNTL, DMCUB_SOFT_RESET, 1); 81 81 REG_UPDATE(DMCUB_CNTL, DMCUB_ENABLE, 0); 82 82 REG_UPDATE(MMHUBBUB_SOFT_RESET, DMUIF_SOFT_RESET, 1); 83 + REG_WRITE(DMCUB_INBOX1_RPTR, 0); 84 + REG_WRITE(DMCUB_INBOX1_WPTR, 0); 83 85 } 84 86 85 87 void dmub_dcn20_reset_release(struct dmub_srv *dmub) ··· 192 190 193 191 REG_WRITE(DMCUB_INBOX1_BASE_ADDRESS, 0x80000000); 194 192 REG_WRITE(DMCUB_INBOX1_SIZE, inbox1->top - inbox1->base); 195 - REG_WRITE(DMCUB_INBOX1_RPTR, 0); 196 - REG_WRITE(DMCUB_INBOX1_WPTR, 0); 197 193 } 198 194 199 195 uint32_t dmub_dcn20_get_inbox1_rptr(struct dmub_srv *dmub)