diff options
author | Ville Syrjälä <[email protected]> | 2020-01-24 22:02:25 +0200 |
---|---|---|
committer | Ville Syrjälä <[email protected]> | 2020-02-14 23:34:16 +0200 |
commit | a7a131ac18a23d31f572cac4cd20581e56add932 (patch) | |
tree | 69d03063050ce8cd1a019b067fb449940483c338 /lib/test_fortify/write_overflow-strcpy.c | |
parent | 7304b9810a7367131dc26ced61696e7c98dd6666 (diff) |
drm/edid: Don't accept any old garbage as a display descriptor
Currently we assume any 18 byte descriptor to be a display descritor
if only the tag byte matches the expected value. But for detailed
timing descriptors that same byte is just the lower 8 bits of
hblank, and as such can match any display descriptor tag. To
properly validate that the 18 byte descriptor is in fact a
display descriptor we must also examine bytes 0-2 (just byte 1
should actually suffice but the spec does say that bytes 0 and
2 must also always be zero for display descriptors so we check
those too).
Unlike Allen's original proposed patch to just fix is_rb() we
roll this out across the board to fix everything.
Cc: Allen Chen <[email protected]>
Signed-off-by: Ville Syrjälä <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Acked-by: Alex Deucher <[email protected]>
Reviewed-by: Uma Shankar <[email protected]>
Diffstat (limited to 'lib/test_fortify/write_overflow-strcpy.c')
0 files changed, 0 insertions, 0 deletions