Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/amd/display: remove redundant null check of array 'data'

The null check on aconnector->base.edid_blob_ptr->data is redundant
since data is an array and can never be null. Remove it.

Detected by CoverityScan, CID#1460369 ("Array compared against 0")

Acked-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

authored by

Colin Ian King and committed by
Alex Deucher
a89ff457 a7ea6548

+1 -2
+1 -2
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
··· 2725 2725 }; 2726 2726 struct edid *edid; 2727 2727 2728 - if (!aconnector->base.edid_blob_ptr || 2729 - !aconnector->base.edid_blob_ptr->data) { 2728 + if (!aconnector->base.edid_blob_ptr) { 2730 2729 DRM_ERROR("No EDID firmware found on connector: %s ,forcing to OFF!\n", 2731 2730 aconnector->base.name); 2732 2731