drm/amd/display: do not dereference on NULL
authorNirmoy Das <nirmoy.das@amd.com>
Thu, 27 May 2021 12:03:33 +0000 (14:03 +0200)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 2 Jun 2021 02:36:57 +0000 (22:36 -0400)
commit57738ae40f33c8903e84863acb17cb7c919d69a3
tree0e28dccb8e891222e737a4dcaac333aaf821a499
parent16eb48c62bd3ff1a523cd1d59591e694bd60277a
drm/amd/display: do not dereference on NULL

WARN_ON() will not kill the process so the second WARN_ON()
will try to dereference NULL pointer.

Signed-off-by: Nirmoy Das <nirmoy.das@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c