]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdgpu: potential NULL dereference in debugfs code
authorDan Carpenter <dan.carpenter@oracle.com>
Wed, 12 Oct 2016 06:17:30 +0000 (09:17 +0300)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 13 Oct 2016 22:25:50 +0000 (18:25 -0400)
commitcf5f04f1203605daa9e91b9d425a47d475bd7556
tree3c194552a9b4ce732788d8486e2fa846bd1adae4
parent6e3f2396f59a432ce6a2c48607743e5c8f2fe698
drm/amdgpu: potential NULL dereference in debugfs code

debugfs_create_file() returns NULL on error, it only returns error
pointers if debugfs isn't enabled in the config and we checked for that
earlier so it can't happen.

Fixes: 216aa1281455 ('drm/amd/amdgpu: Convert ring debugfs entries to binary')
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c