From: Simon Ser <simon.ser@intel.com>
To: igt-dev@lists.freedesktop.org
Subject: [igt-dev] [PATCH i-g-t] tests/kms_hdmi_inject: document how the test works
Date: Mon, 20 May 2019 17:59:04 +0300 [thread overview]
Message-ID: <20190520145904.23240-1-simon.ser@intel.com> (raw)
It's not immediately obvious what injection and ELDs are, and what is tested.
This commit adds a few comments to help readers understand this test. In case
the test breaks, this could help.
Signed-off-by: Simon Ser <simon.ser@intel.com>
---
Suggestions wrt. more things to add and rewords are welcome!
I also noticed that there were already functions to generate audio-capable
EDIDs in IGT. Future work includes:
- Unifying kmstest_edid_add_audio and igt_edid (same for 4k helpers)
- Make the injection tests work on DisplayPort
- Test more EDIDs (e.g. more formats/sample sizes combinations)
- Also run tests with the same EDIDs with the Chamelium
tests/kms_hdmi_inject.c | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
diff --git a/tests/kms_hdmi_inject.c b/tests/kms_hdmi_inject.c
index 699bad5b73e2..a24061042c20 100644
--- a/tests/kms_hdmi_inject.c
+++ b/tests/kms_hdmi_inject.c
@@ -30,6 +30,22 @@
IGT_TEST_DESCRIPTION("Tests 4K and audio HDMI injection.");
+/**
+ * This collection of tests performs EDID and status injection tests. Injection
+ * forces a given EDID and status on a connector. The kernel will parse the
+ * forced EDID and we will check whether correct metadata is exposed to
+ * userspace.
+ *
+ * Currently, this can be used to test:
+ *
+ * - 4K modes exposed via KMS
+ * - Audio capabilities of the monitor exposed via ALSA. EDID-Like Data (ELD)
+ * entries in /proc/asound are verified.
+ *
+ * Injection is performed on a disconnected connector.
+ */
+
+/** get_connector: get the first disconnected HDMI connector */
static drmModeConnector *
get_connector(int drm_fd, drmModeRes *res)
{
@@ -118,6 +134,7 @@ hdmi_inject_4k(int drm_fd, drmModeConnector *connector)
free(edid);
}
+/** eld_entry_is_igt: checks whether an ELD entry is mapped to the IGT EDID */
static bool
eld_entry_is_igt(const char* path)
{
@@ -154,6 +171,8 @@ eld_entry_is_igt(const char* path)
return false;
}
+/** eld_is_valid: check whether ALSA has detected the audio-capable IGT EDID by
+ * parsing ELD entries */
static bool
eld_is_valid(void)
{
--
2.21.0
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
next reply other threads:[~2019-05-20 14:59 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-20 14:59 Simon Ser [this message]
2019-05-21 10:36 ` [igt-dev] ✗ Fi.CI.BAT: failure for tests/kms_hdmi_inject: document how the test works (rev2) Patchwork
2019-05-21 10:48 ` Ser, Simon
2019-05-23 8:28 ` [igt-dev] ✓ Fi.CI.BAT: success for tests/kms_hdmi_inject: document how the test works (rev3) Patchwork
2019-05-24 2:12 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2019-05-24 13:55 ` [igt-dev] [PATCH i-g-t] tests/kms_hdmi_inject: document how the test works Arkadiusz Hiler
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190520145904.23240-1-simon.ser@intel.com \
--to=simon.ser@intel.com \
--cc=igt-dev@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.