[AMD Official Use Only - General] Nice catch. Reviewed-by: Yifan Zhang <yifan1.zhang@xxxxxxx> -----Original Message----- From: Huang, Tim <Tim.Huang@xxxxxxx> Sent: Wednesday, April 3, 2024 6:18 PM To: amd-gfx@xxxxxxxxxxxxxxxxxxxxx Cc: Deucher, Alexander <Alexander.Deucher@xxxxxxx>; Zhang, Yifan <Yifan1.Zhang@xxxxxxx>; Zhang, Hawking <Hawking.Zhang@xxxxxxx>; Huang, Tim <Tim.Huang@xxxxxxx> Subject: [PATCH] drm/amdgpu: fix incorrect number of active RBs for gfx11 From: Tim Huang <Tim.Huang@xxxxxxx> The RB bitmap should be global active RB bitmap & active RB bitmap based on active SA. Signed-off-by: Tim Huang <Tim.Huang@xxxxxxx> --- 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