[PATCH edid-decode 3/3] Print the correct VIC number next to the mode
Thomas Wood
thomas.wood at intel.com
Fri Sep 27 04:27:01 PDT 2013
Signed-off-by: Thomas Wood <thomas.wood at intel.com>
---
edid-decode.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/edid-decode.c b/edid-decode.c
index b710bb5..4265843 100644
--- a/edid-decode.c
+++ b/edid-decode.c
@@ -715,10 +715,11 @@ cea_video_block(unsigned char *x)
unsigned char vic = x[i] & 0x7f;
unsigned char native = x[i] & 0x80;
const char *mode;
+ int index;
- vic--;
- if (vic < ARRAY_SIZE(edid_cea_modes))
- mode = edid_cea_modes[vic];
+ index = vic - 1;
+ if (index < ARRAY_SIZE(edid_cea_modes))
+ mode = edid_cea_modes[index];
else
mode = "Unknown mode";
--
1.8.3.1
More information about the dri-devel
mailing list