Hi Yongjun,
This issue has been fixed. Thanks. Best Regards Rex commit 51f1f6f51712aade68cabb145ed8bab4a6c3997e Author: Rex Zhu <rex....@amd.com> Date: Fri Nov 23 18:52:21 2018 +0800 drm/amdgpu: Fix static checker warning drivers/gpu/drm/amd/amdgpu/amdgpu_csa.c:49 amdgpu_allocate_static_csa() error: uninitialized symbol 'ptr'. the test if (!bo) doesn't work, as the bo is a pointer to a pointer. if bo create failed, the *bo will be set to NULL. so change to test *bo. Reviewed-by: Christian König <christian.koe...@amd.com> Signed-off-by: Rex Zhu <rex....@amd.com> Signed-off-by: Alex Deucher <alexander.deuc...@amd.com> ________________________________ From: Wei Yongjun <weiyongj...@huawei.com> Sent: Tuesday, December 4, 2018 2:39 PM To: Deucher, Alexander; Koenig, Christian; Zhou, David(ChunMing); airl...@linux.ie; Zhu, Rex; Liu, Monk Cc: Wei Yongjun; amd-gfx@lists.freedesktop.org; dri-de...@lists.freedesktop.org; linux-ker...@vger.kernel.org; kernel-janit...@vger.kernel.org Subject: [PATCH -next] drm/amdgpu: Fix return value check in amdgpu_allocate_static_csa() Fix the return value check which testing the wrong variable in amdgpu_allocate_static_csa(). Fixes: 7946340fa389 ("drm/amdgpu: Move csa related code to separate file") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_csa.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_csa.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_csa.c index 0c590dd..a5fbc6f 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_csa.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_csa.c @@ -43,7 +43,7 @@ int amdgpu_allocate_static_csa(struct amdgpu_device *adev, struct amdgpu_bo **bo r = amdgpu_bo_create_kernel(adev, size, PAGE_SIZE, domain, bo, NULL, &ptr); - if (!bo) + if (!r) return -ENOMEM; memset(ptr, 0, size);
_______________________________________________ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx