drm/edid: Don't include ext block csum in DispID size

The EDID extension block checksum byte is not part of the
actual DispID data, so don't use it in validate_displayid().

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200313162054.16009-8-ville.syrjala@linux.intel.com
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
Ville Syrjälä 2020-03-13 18:20:52 +02:00
parent 8e88c75245
commit 5f706b4a3b
1 changed files with 2 additions and 1 deletions

View File

@ -3222,7 +3222,8 @@ static u8 *drm_find_displayid_extension(const struct edid *edid,
if (!displayid) if (!displayid)
return NULL; return NULL;
*length = EDID_LENGTH; /* EDID extensions block checksum isn't for us */
*length = EDID_LENGTH - 1;
*idx = 1; *idx = 1;
ret = validate_displayid(displayid, *length, *idx); ret = validate_displayid(displayid, *length, *idx);