aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm
diff options
context:
space:
mode:
authorMarkus Elfring <elfring@users.sourceforge.net>2014-11-25 07:44:20 -0500
committerRob Clark <robdclark@gmail.com>2014-12-17 10:59:49 -0500
commit5acb07ea802c3a06bbe22cba32fbb8eb97b6b3ae (patch)
tree6bbecbe9dd9122d4958955962653ba15e1e8c88f /drivers/gpu/drm
parent264f7d673fad394d8ed6b17fa9c16e2e62fa0c4e (diff)
drm/msm: Deletion of unnecessary checks before the function call "release_firmware"
The release_firmware() function tests whether its argument is NULL and then returns immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Reviewed-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Rob Clark <robdclark@gmail.com>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r--drivers/gpu/drm/msm/adreno/adreno_gpu.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/gpu/drm/msm/adreno/adreno_gpu.c b/drivers/gpu/drm/msm/adreno/adreno_gpu.c
index aa873048308b..94a5bee69fe7 100644
--- a/drivers/gpu/drm/msm/adreno/adreno_gpu.c
+++ b/drivers/gpu/drm/msm/adreno/adreno_gpu.c
@@ -386,9 +386,7 @@ void adreno_gpu_cleanup(struct adreno_gpu *gpu)
386 msm_gem_put_iova(gpu->memptrs_bo, gpu->base.id); 386 msm_gem_put_iova(gpu->memptrs_bo, gpu->base.id);
387 drm_gem_object_unreference(gpu->memptrs_bo); 387 drm_gem_object_unreference(gpu->memptrs_bo);
388 } 388 }
389 if (gpu->pm4) 389 release_firmware(gpu->pm4);
390 release_firmware(gpu->pm4); 390 release_firmware(gpu->pfp);
391 if (gpu->pfp)
392 release_firmware(gpu->pfp);
393 msm_gpu_cleanup(&gpu->base); 391 msm_gpu_cleanup(&gpu->base);
394} 392}