[PATCH v3] drm/amdkfd: Remove bo NULL check in gmc_v12_0_get_vm_pte() function

Dan Carpenter dan.carpenter at linaro.org
Wed May 15 06:53:05 UTC 2024


On Tue, May 14, 2024 at 08:31:03PM -0400, Sreekant Somasekharan wrote:
> Remove bo NULL check in amdgpu/gmc_v12_0.c:gmc_v12_0_get_vm_pte() function
> to fix smatch warning:
> 
> 'drivers/gpu/drm/amd/amdgpu/gmc_v12_0.c:518 gmc_v12_0_get_vm_pte()
> warn: variable dereferenced before check 'bo' (see line 500)'
> 
> Signed-off-by: Sreekant Somasekharan <sreekant.somasekharan at amd.com>
> Suggested-by: Dan Carpenter <dan.carpenter at linaro.org>
> ---

This is fine, but you're overthinking these...  The v1 patch was also
fine.

regards,
dan carpenter





More information about the amd-gfx mailing list