RE: [PATCH] drm/amdgpu: Fix unused variable ‘i’ in 'gfxhub_v1_2_xcc_gart_enable'

Chen, Guchun Guchun.Chen at amd.com
Wed Aug 2 01:41:47 UTC 2023


[Public]

Reviewed-by: Guchun Chen <guchun.chen at amd.com>

> -----Original Message-----
> From: SHANMUGAM, SRINIVASAN <SRINIVASAN.SHANMUGAM at amd.com>
> Sent: Wednesday, August 2, 2023 9:39 AM
> To: Koenig, Christian <Christian.Koenig at amd.com>; Deucher, Alexander
> <Alexander.Deucher at amd.com>; Chen, Guchun <Guchun.Chen at amd.com>;
> Pan, Xinhui <Xinhui.Pan at amd.com>
> Cc: amd-gfx at lists.freedesktop.org; SHANMUGAM, SRINIVASAN
> <SRINIVASAN.SHANMUGAM at amd.com>
> Subject: [PATCH] drm/amdgpu: Fix unused variable ‘i’ in
> 'gfxhub_v1_2_xcc_gart_enable'
>
> drivers/gpu/drm/amd/amdgpu/gfxhub_v1_2.c: In function
> ‘gfxhub_v1_2_xcc_gart_enable’:
> drivers/gpu/drm/amd/amdgpu/gfxhub_v1_2.c:405:6: warning: unused
> variable ‘i’ [-Wunused-variable]
>   405 |  int i;
>       |
>
> Cc: Guchun Chen <guchun.chen at amd.com>
> Cc: Christian König <christian.koenig at amd.com>
> Cc: Alex Deucher <alexander.deucher at amd.com>
> Cc: "Pan, Xinhui" <Xinhui.Pan at amd.com>
> Signed-off-by: Srinivasan Shanmugam <srinivasan.shanmugam at amd.com>
> ---
>  drivers/gpu/drm/amd/amdgpu/gfxhub_v1_2.c | 2 --
>  1 file changed, 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/gfxhub_v1_2.c
> b/drivers/gpu/drm/amd/amdgpu/gfxhub_v1_2.c
> index db7ad3af7439..0834af771549 100644
> --- a/drivers/gpu/drm/amd/amdgpu/gfxhub_v1_2.c
> +++ b/drivers/gpu/drm/amd/amdgpu/gfxhub_v1_2.c
> @@ -402,8 +402,6 @@ static void
> gfxhub_v1_2_xcc_program_invalidation(struct amdgpu_device *adev,  static
> int gfxhub_v1_2_xcc_gart_enable(struct amdgpu_device *adev,
>                                      uint32_t xcc_mask)
>  {
> -     int i;
> -
>       /* GART Enable. */
>       gfxhub_v1_2_xcc_init_gart_aperture_regs(adev, xcc_mask);
>       gfxhub_v1_2_xcc_init_system_aperture_regs(adev, xcc_mask);
> --
> 2.25.1



More information about the amd-gfx mailing list