drm/amd/display: Fix amdgpu_dm bugs found by smatch
authorHarry Wentland <harry.wentland@amd.com>
Fri, 10 Nov 2017 16:19:02 +0000 (11:19 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 28 Nov 2017 22:56:03 +0000 (17:56 -0500)
commit70e8ffc55b98f31af700eae525fef5d0b8fcb6e1
tree4677cfccd4f6623485fd5ebb7ca5186810f5b502
parentcfb071f7a9673109415d097125b3c12c16836acc
drm/amd/display: Fix amdgpu_dm bugs found by smatch

drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm.c:2760
create_eml_sink() warn: variable dereferenced before check
'aconnector->base.edid_blob_ptr' (see line 2758)
drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm.c:4270
amdgpu_dm_atomic_commit_tail() warn: variable dereferenced before check
'dm_new_crtc_state->stream' (see line 4266)
drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm.c:4417
dm_restore_drm_connector_state() warn: variable dereferenced before
check 'disconnected_acrtc' (see line 4415)

Signed-off-by: Harry Wentland <harry.wentland@amd.com>
Reviewed-by: Sun peng Li <Sunpeng.Li@amd.com>
Acked-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c