[PATCH v2] drm/amdgpu: Remove unreachable code in amdgpu/atom.c
SRINIVASAN SHANMUGAM
srinivasan.shanmugam at amd.com
Wed Dec 27 10:21:59 UTC 2023
Please ignore the change for "static uint32_t atom_get_src_int", this
doesn't fix the warning, will try to send updated version.
On 12/27/2023 3:34 PM, SHANMUGAM, SRINIVASAN wrote:
> Fixes the below:
> drivers/gpu/drm/amd/amdgpu/atom.c:316 atom_get_src_int() warn: ignoring unreachable code.
> drivers/gpu/drm/amd/amdgpu/atom.c:398 atom_skip_src_int() warn: ignoring unreachable code.
>
> Cc: Christian König<christian.koenig at amd.com>
> Cc: Alex Deucher<alexander.deucher at amd.com>
> Signed-off-by: Srinivasan Shanmugam<srinivasan.shanmugam at amd.com>
> ---
> v2:
> Removed below redundant code from v1
> + val = 0;
> + break;
>
>
> drivers/gpu/drm/amd/amdgpu/atom.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/atom.c b/drivers/gpu/drm/amd/amdgpu/atom.c
> index 2c221000782c..10ec7d75ce7b 100644
> --- a/drivers/gpu/drm/amd/amdgpu/atom.c
> +++ b/drivers/gpu/drm/amd/amdgpu/atom.c
> @@ -313,7 +313,6 @@ static uint32_t atom_get_src_int(atom_exec_context *ctx, uint8_t attr,
> DEBUG("IMM 0x%02X\n", val);
> return val;
> }
> - return 0;
> case ATOM_ARG_PLL:
> idx = U8(*ptr);
> (*ptr)++;
> @@ -395,7 +394,6 @@ static void atom_skip_src_int(atom_exec_context *ctx, uint8_t attr, int *ptr)
> (*ptr)++;
> return;
> }
> - return;
> }
> }
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/amd-gfx/attachments/20231227/1e805dc1/attachment-0001.htm>
More information about the amd-gfx
mailing list