drm/amdgpu: clear RB_OVERFLOW bit when enabling interrupts
authorDanijel Slivka <danijel.slivka@amd.com>
Mon, 24 Jun 2024 05:58:24 +0000 (07:58 +0200)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 27 Jun 2024 21:30:27 +0000 (17:30 -0400)
commitafbf7955ff01e952dbdd465fa25a2ba92d00291c
treeb8c0ef1bf2b1621bb292f7d8d4e2977ee85ce5f3
parentbf826ba9b4b17fb2bff507b8391a8e4babd227fa
drm/amdgpu: clear RB_OVERFLOW bit when enabling interrupts

Why:
Setting IH_RB_WPTR register to 0 will not clear the RB_OVERFLOW bit
if RB_ENABLE is not set.

How to fix:
Set WPTR_OVERFLOW_CLEAR bit after RB_ENABLE bit is set.
The RB_ENABLE bit is required to be set, together with
WPTR_OVERFLOW_ENABLE bit so that setting WPTR_OVERFLOW_CLEAR bit
would clear the RB_OVERFLOW.

Signed-off-by: Danijel Slivka <danijel.slivka@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/ih_v6_0.c