commit | bfaa1ce809bbcd12b1399409ab1dbf0cdaba6e27 | [log] [tgz] |
---|---|---|
author | Colin Ian King <colin.king@canonical.com> | Fri Sep 08 15:13:33 2017 +0100 |
committer | Oded Gabbay <oded.gabbay@gmail.com> | Fri Sep 08 15:13:33 2017 +0100 |
tree | d9756188eedec6d415652f8d7cad20d229f61dc0 | |
parent | 56eac98b8a0bbb72132340dbfedc912c68c4bd56 [diff] |
drm/amdkfd: check for null dev to avoid a null pointer dereference The call to kfd_device_by_id can potentially return null, so check that dev is null and return with -EINVAL to avoid a null pointer dereference. Detected by CoverityScan CID#1454629 ("Dereference null return value") Fixes: 5d71dbc3a588 ("drm/amdkfd: Implement image tiling mode support v2") Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>