[igt-dev] [PATCH i-g-t 3/3] lib/tests/igt_edid: check number of extensions
Simon Ser
simon.ser at intel.com
Fri Jul 5 13:08:39 UTC 2019
Make sure we don't miss an extension by verifying the EDID field.
Signed-off-by: Simon Ser <simon.ser at intel.com>
---
lib/tests/igt_edid.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/lib/tests/igt_edid.c b/lib/tests/igt_edid.c
index e15748286ac0..fc98f1bb71ce 100644
--- a/lib/tests/igt_edid.c
+++ b/lib/tests/igt_edid.c
@@ -92,6 +92,9 @@ igt_simple_main
igt_assert_f(edid_block_checksum(edid),
"checksum failed on %s EDID", f->desc);
/* check extension blocks, if any */
+ igt_assert_f(edid[126] == f->exts,
+ "unexpected number of extensions on %s EDID",
+ f->desc);
for (i = 0; i < f->exts; i++)
igt_assert_f(edid_block_checksum(edid + (i + 1) * EDID_LENGTH),
"CEA block checksum failed on %s EDID", f->desc);
--
2.22.0
More information about the igt-dev
mailing list