drm/amdgpu: fix a build warning by a typo in amdgpu_gfx.c
Subsystems (2)
PATCH 1/1 drm/amdgpu: fix a build warning by a typo in amdgpu_gfx.c
This should be a typo when intruducing multi-xx support.
Reported-by kernel test robot <[email protected]>
Signed-off-by Guchun Chen <[email protected]>
Cc Le Ma <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c +2 -2
@@ -470,8 +470,8 @@ void amdgpu_gfx_mqd_sw_fini(struct amdgpu_device *adev, int xcc_id)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { j = i + xcc_id * adev->gfx.num_compute_rings; - ring = &adev->gfx.compute_ring[i]; -kfree (adev->gfx.mec.mqd_backup[i]); + ring = &adev->gfx.compute_ring[j]; +kfree (adev->gfx.mec.mqd_backup[j]);amdgpu_bo_free_kernel (&ring->mqd_obj, &ring->mqd_gpu_addr, &ring->mqd_ptr);
Signature · 1 line
2.25.1
[AMD Official Use Only - General]
Reviewed-by Le Ma <[email protected]>
Quoted 37 lines
-----Original Message-----
From: Chen, Guchun <[email protected]>
Sent: Wednesday, April 26, 2023 11:12 AM
To: [email protected]; Deucher, Alexander <[email protected]>; Zhang, Hawking <[email protected]>; Ma, Le <[email protected]>
Cc: Chen, Guchun <[email protected]>; kernel test robot <[email protected]>
Subject: [PATCH] drm/amdgpu: fix a build warning by a typo inamdgpu_gfx.cThis should be a typo when intruducing multi-xx support.
Reported-by kernel test robot <[email protected]>Signed-off-by Guchun Chen <[email protected]>Cc Le Ma <[email protected]>--- drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c +2
-2@@ -470,8 +470,8 @@ void amdgpu_gfx_mqd_sw_fini(struct amdgpu_device *adev, int xcc_id)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { j = i + xcc_id * adev->gfx.num_compute_rings; - ring = &adev->gfx.compute_ring[i]; -kfree (adev->gfx.mec.mqd_backup[i]); + ring = &adev->gfx.compute_ring[j]; +kfree (adev->gfx.mec.mqd_backup[j]); amdgpu_bo_free_kernel(&ring->mqd_obj, &ring->mqd_gpu_addr,&ring->mqd_ptr);--
2.25.1
Am 26.04.23 um 05:11 schrieb Guchun Chen:
Quoted 5 lines
This should be a typo when intruducing multi-xx support.
Reported-by kernel test robot <[email protected]>Signed-off-by Guchun Chen <[email protected]>Cc Le Ma <[email protected]>
Acked-by Christian König <[email protected]>
Quoted 19 lines
--- drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c +2
-2@@ -470,8 +470,8 @@ void amdgpu_gfx_mqd_sw_fini(struct amdgpu_device *adev, int xcc_id)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { j = i + xcc_id * adev->gfx.num_compute_rings; - ring = &adev->gfx.compute_ring[i]; -kfree (adev->gfx.mec.mqd_backup[i]); + ring = &adev->gfx.compute_ring[j]; +kfree (adev->gfx.mec.mqd_backup[j]);amdgpu_bo_free_kernel (&ring->mqd_obj, &ring->mqd_gpu_addr, &ring->mqd_ptr);