]> Git Repo - linux.git/commitdiff
drm/amdgpu: Add a read after write DB_CTRL for vcn_v4_0_3
authorSonny Jiang <[email protected]>
Tue, 28 Mar 2023 17:19:11 +0000 (13:19 -0400)
committerAlex Deucher <[email protected]>
Fri, 9 Jun 2023 13:56:26 +0000 (09:56 -0400)
To make sure VCN DB_CTRL is delivered before doorbell write.

Signed-off-by: Sonny Jiang <[email protected]>
Reviewed-by: Lijo Lazar <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c

index b0e28d611f2d1137d23e07f00302f4704210542b..9d0c3dc765472ecf11e9a95d2ce9e863a40d1fb5 100644 (file)
@@ -195,6 +195,11 @@ static int vcn_v4_0_3_hw_init(void *handle)
                                ring->doorbell_index
                                                << VCN_RB1_DB_CTRL__OFFSET__SHIFT |
                                        VCN_RB1_DB_CTRL__EN_MASK);
+
+                       /* Read DB_CTRL to flush the write DB_CTRL command. */
+                       RREG32_SOC15(
+                               VCN, GET_INST(VCN, ring->me),
+                               regVCN_RB1_DB_CTRL);
                }
 
                r = amdgpu_ring_test_helper(ring);
This page took 0.06063 seconds and 4 git commands to generate.