[PATCH] drm/amdgpu: Make umc_v8_10_convert_error_address static and remove unused variable
Zhou1, Tao
Tao.Zhou1 at amd.com
Fri Feb 24 05:58:37 UTC 2023
Reviewed-by: Tao Zhou <tao.zhou1 at amd.com>
> -----Original Message-----
> From: amd-gfx <amd-gfx-bounces at lists.freedesktop.org> On Behalf Of Candice
> Li
> Sent: Friday, February 24, 2023 12:25 PM
> To: amd-gfx at lists.freedesktop.org
> Cc: Li, Candice <Candice.Li at amd.com>
> Subject: [PATCH] drm/amdgpu: Make umc_v8_10_convert_error_address static
> and remove unused variable
>
> Fixes following warnings:
> warning: no previous prototype for 'umc_v8_10_convert_error_address'
> warning: variable 'channel_index' set but not used
>
> Reported-by: kernel test robot <lkp at intel.com>
> Signed-off-by: Candice Li <candice.li at amd.com>
> ---
> drivers/gpu/drm/amd/amdgpu/umc_v8_10.c | 15 +++++----------
> 1 file changed, 5 insertions(+), 10 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/umc_v8_10.c
> b/drivers/gpu/drm/amd/amdgpu/umc_v8_10.c
> index 66158219f791cb..fb55e8cb9967ad 100644
> --- a/drivers/gpu/drm/amd/amdgpu/umc_v8_10.c
> +++ b/drivers/gpu/drm/amd/amdgpu/umc_v8_10.c
> @@ -209,10 +209,10 @@ static int umc_v8_10_swizzle_mode_na_to_pa(struct
> amdgpu_device *adev,
> return 0;
> }
>
> -void umc_v8_10_convert_error_address(struct amdgpu_device *adev,
> - struct ras_err_data *err_data, uint64_t
> err_addr,
> - uint32_t ch_inst, uint32_t umc_inst,
> - uint32_t node_inst, uint64_t mc_umc_status)
> +static void umc_v8_10_convert_error_address(struct amdgpu_device *adev,
> + struct ras_err_data *err_data,
> uint64_t err_addr,
> + uint32_t ch_inst, uint32_t umc_inst,
> + uint32_t node_inst, uint64_t
> mc_umc_status)
> {
> uint64_t na_err_addr_base;
> uint64_t na_err_addr, retired_page_addr; @@ -434,7 +434,7 @@ static
> void umc_v8_10_ecc_info_query_error_address(struct amdgpu_device *adev,
> uint32_t umc_inst,
> uint32_t node_inst)
> {
> - uint32_t eccinfo_table_idx, channel_index;
> + uint32_t eccinfo_table_idx;
> uint64_t mc_umc_status, err_addr;
>
> struct amdgpu_ras *ras = amdgpu_ras_get_context(adev); @@ -443,11
> +443,6 @@ static void umc_v8_10_ecc_info_query_error_address(struct
> amdgpu_device *adev,
> adev->umc.channel_inst_num +
> umc_inst * adev->umc.channel_inst_num +
> ch_inst;
> - channel_index =
> - adev->umc.channel_idx_tbl[node_inst * adev-
> >umc.umc_inst_num *
> - adev->umc.channel_inst_num
> +
> - umc_inst * adev-
> >umc.channel_inst_num +
> - ch_inst];
>
> mc_umc_status = ras-
> >umc_ecc.ecc[eccinfo_table_idx].mca_umc_status;
>
> --
> 2.17.1
More information about the amd-gfx
mailing list