[PATCH 11/12] drm/amdkfd: remove logically dead code
Felix Kuehling
felix.kuehling at amd.com
Tue Jun 4 18:39:57 UTC 2024
On 2024-06-03 04:49, Jesse Zhang wrote:
> idr_for_each_entry can ensure that mem is not empty during the loop.
> So don't need check mem again.
>
> Signed-off-by: Jesse Zhang <Jesse.Zhang at amd.com>
Reviewed-by: Felix Kuehling <felix.kuehling at amd.com>
> ---
> drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 5 -----
> 1 file changed, 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_chardev.c b/drivers/gpu/drm/amd/amdkfd/kfd_chardev.c
> index fdf171ad4a3c..32e5db509560 100644
> --- a/drivers/gpu/drm/amd/amdkfd/kfd_chardev.c
> +++ b/drivers/gpu/drm/amd/amdkfd/kfd_chardev.c
> @@ -1913,11 +1913,6 @@ static int criu_checkpoint_bos(struct kfd_process *p,
> struct kfd_criu_bo_priv_data *bo_priv;
> int i, dev_idx = 0;
>
> - if (!mem) {
> - ret = -ENOMEM;
> - goto exit;
> - }
> -
> kgd_mem = (struct kgd_mem *)mem;
> dumper_bo = kgd_mem->bo;
>
More information about the amd-gfx
mailing list