summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm
diff options
context:
space:
mode:
authorThomas Wood <thomas.wood@intel.com>2013-11-29 15:33:26 +0000
committerDave Airlie <airlied@redhat.com>2013-12-05 11:00:51 +1000
commit7d14b95f1a3bb20bf7ad977b9268c5d1639156e2 (patch)
treeb9257ad4bd9404d99ffacedf5e2e487b081e7a77 /drivers/gpu/drm
parent1ec2c7fc1100ca91ebedb583aef80a5e9aafdabd (diff)
downloadlinux-7d14b95f1a3bb20bf7ad977b9268c5d1639156e2.tar.gz
linux-7d14b95f1a3bb20bf7ad977b9268c5d1639156e2.tar.bz2
linux-7d14b95f1a3bb20bf7ad977b9268c5d1639156e2.zip
drm/edid: fix length check when adding extra 3D modes
Signed-off-by: Thomas Wood <thomas.wood@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r--drivers/gpu/drm/drm_edid.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c
index fb7cf0e796f6..381c698e8a3e 100644
--- a/drivers/gpu/drm/drm_edid.c
+++ b/drivers/gpu/drm/drm_edid.c
@@ -2674,7 +2674,7 @@ static int add_3d_struct_modes(struct drm_connector *connector, u16 structure,
int modes = 0;
u8 cea_mode;
- if (video_db == NULL || video_index > video_len)
+ if (video_db == NULL || video_index >= video_len)
return 0;
/* CEA modes are numbered 1..127 */