Re: [amd-gfx] [PATCH] drm/amdgpu: fix num_rbs exposed to userspace

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 17.06.2016 16:20, Alex Deucher wrote:
This was accidently broken for harvest cards when the
code was refactored for Polaris support.

Signed-off-by: Alex Deucher <alexander.deucher@xxxxxxx>
Cc: stable@xxxxxxxxxxxxxxx
---
  drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
index 9ab28ca..e5c22cd 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
@@ -459,7 +459,7 @@ static int amdgpu_info_ioctl(struct drm_device *dev, void *data, struct drm_file
  			dev_info.max_memory_clock = adev->pm.default_mclk * 10;
  		}
  		dev_info.enabled_rb_pipes_mask = adev->gfx.config.backend_enable_mask;
-		dev_info.num_rb_pipes = adev->gfx.config.num_rbs;
+		dev_info.num_rb_pipes = adev->gfx.config.max_backends_per_se;

At a glance, that looks suspicious to me. num_rb_pipes becomes rb_pipes in libdrmm and then num_render_backends. We divide num_render_backends by the number of SEs * SHs in radeonsi.

In a nutshell, radeonsi expects this to be the total number of RBs (including disabled/harvested ones).

Nicolai

  		dev_info.num_hw_gfx_contexts = adev->gfx.config.max_hw_contexts;
  		dev_info._pad = 0;
  		dev_info.ids_flags = 0;

--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]