[AMD Official Use Only - General]

Nice catch.

Reviewed-by: Yifan Zhang <yifan1.zh...@amd.com>

-----Original Message-----
From: Huang, Tim <tim.hu...@amd.com>
Sent: Wednesday, April 3, 2024 6:18 PM
To: amd-gfx@lists.freedesktop.org
Cc: Deucher, Alexander <alexander.deuc...@amd.com>; Zhang, Yifan 
<yifan1.zh...@amd.com>; Zhang, Hawking <hawking.zh...@amd.com>; Huang, Tim 
<tim.hu...@amd.com>
Subject: [PATCH] drm/amdgpu: fix incorrect number of active RBs for gfx11

From: Tim Huang <tim.hu...@amd.com>

The RB bitmap should be global active RB bitmap & active RB bitmap based on 
active SA.

Signed-off-by: Tim Huang <tim.hu...@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/gfx_v11_0.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v11_0.c 
b/drivers/gpu/drm/amd/amdgpu/gfx_v11_0.c
index 7a906318e451..07cdeef9d44a 100644
--- a/drivers/gpu/drm/amd/amdgpu/gfx_v11_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/gfx_v11_0.c
@@ -1635,7 +1635,7 @@ static void gfx_v11_0_setup_rb(struct amdgpu_device *adev)
                        active_rb_bitmap |= (0x3 << (i * 
rb_bitmap_width_per_sa));
        }

-       active_rb_bitmap |= global_active_rb_bitmap;
+       active_rb_bitmap &= global_active_rb_bitmap;
        adev->gfx.config.backend_enable_mask = active_rb_bitmap;
        adev->gfx.config.num_rbs = hweight32(active_rb_bitmap);  }
--
2.39.2

Reply via email to