]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amd/amdgpu/amdgpu_ttm: Handle return NULL error from ioremap_nocache
authorArvind Yadav <arvind.yadav.cs@gmail.com>
Tue, 24 Jan 2017 09:25:33 +0000 (14:55 +0530)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 27 Jan 2017 17:20:38 +0000 (12:20 -0500)
commit22f9ed1684e521640206200e64740a14f3ff7995
tree68aff7e691359fc5db0d797c4bcd1d7cca6de0f6
parentd3b4e605258464a2e411771d637237022c0a77ff
drm/amd/amdgpu/amdgpu_ttm: Handle return NULL error from ioremap_nocache

Here, If ioremap_nocache will fail. It will return NULL.
Kernel can run into a NULL-pointer dereference.
This error check will avoid NULL pointer dereference.

Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c