diff options
author | Adam Jackson <ajax@redhat.com> | 2010-08-03 14:38:18 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2010-08-10 10:46:58 +1000 |
commit | cbba98f8f651a763fe9fd167efa65cd7b1fa22d9 (patch) | |
tree | ba25a4baf0cb267102973e697f0d5c552a7c826a /drivers/gpu/drm/drm_edid.c | |
parent | 4d76a22134d5a5ad259fd667f3d2b215b7e71d10 (diff) | |
download | linux-3.10-cbba98f8f651a763fe9fd167efa65cd7b1fa22d9.tar.gz linux-3.10-cbba98f8f651a763fe9fd167efa65cd7b1fa22d9.tar.bz2 linux-3.10-cbba98f8f651a763fe9fd167efa65cd7b1fa22d9.zip |
drm/edid: Add detailed block walk for VTB extensions
Signed-off-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/drm_edid.c')
-rw-r--r-- | drivers/gpu/drm/drm_edid.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c index 30b286ba16c..1bf81b91b70 100644 --- a/drivers/gpu/drm/drm_edid.c +++ b/drivers/gpu/drm/drm_edid.c @@ -712,6 +712,19 @@ cea_for_each_detailed_block(u8 *ext, detailed_cb *cb, void *closure) } static void +vtb_for_each_detailed_block(u8 *ext, detailed_cb *cb, void *closure) +{ + unsigned int i, n = min((int)ext[0x02], 6); + u8 *det_base = ext + 5; + + if (ext[0x01] != 1) + return; /* unknown version */ + + for (i = 0; i < n; i++) + cb((struct detailed_timing *)(det_base + 18 * i), closure); +} + +static void drm_for_each_detailed_block(u8 *raw_edid, detailed_cb *cb, void *closure) { int i; @@ -729,6 +742,9 @@ drm_for_each_detailed_block(u8 *raw_edid, detailed_cb *cb, void *closure) case CEA_EXT: cea_for_each_detailed_block(ext, cb, closure); break; + case VTB_EXT: + vtb_for_each_detailed_block(ext, cb, closure); + break; default: break; } |