From: Paul Kocialkowski <paul.kocialkowski@linux.intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: Lyude <lyude@redhat.com>
Subject: [PATCH i-g-t 5/7] tests/chamelium: Use configurable DUT suspend/resume delay
Date: Mon, 26 Jun 2017 16:59:04 +0300 [thread overview]
Message-ID: <20170626135906.32708-5-paul.kocialkowski@linux.intel.com> (raw)
In-Reply-To: <20170626135906.32708-1-paul.kocialkowski@linux.intel.com>
Now that the suspend/resume delay can be configured in the IGT
configuration (igtrc), use it in the chamelium suspend/resume tests.
Signed-off-by: Paul Kocialkowski <paul.kocialkowski@linux.intel.com>
---
tests/chamelium.c | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)
diff --git a/tests/chamelium.c b/tests/chamelium.c
index 15ed0f28..3ee57af6 100644
--- a/tests/chamelium.c
+++ b/tests/chamelium.c
@@ -42,7 +42,6 @@ typedef struct {
} data_t;
#define HOTPLUG_TIMEOUT 20 /* seconds */
-#define SUSPEND_RESUME_DELAY 20 /* seconds */
#define HPD_STORM_PULSE_INTERVAL_DP 100 /* ms */
#define HPD_STORM_PULSE_INTERVAL_HDMI 200 /* ms */
@@ -222,21 +221,22 @@ try_suspend_resume_hpd(data_t *data, struct chamelium_port *port,
enum igt_suspend_state state, enum igt_suspend_test test,
struct udev_monitor *mon, bool connected)
{
+ int delay = chamelium_get_suspend_resume_delay(data->chamelium);
int p;
- igt_set_autoresume_delay(SUSPEND_RESUME_DELAY);
+ igt_set_autoresume_delay(delay);
igt_flush_hotplugs(mon);
+ delay = delay * 1000 / 2;
+
if (port) {
- chamelium_schedule_hpd_toggle(data->chamelium, port,
- SUSPEND_RESUME_DELAY * 1000 / 2,
+ chamelium_schedule_hpd_toggle(data->chamelium, port, delay,
!connected);
} else {
for (p = 0; p < data->port_count; p++) {
port = data->ports[p];
chamelium_schedule_hpd_toggle(data->chamelium, port,
- SUSPEND_RESUME_DELAY * 1000 / 2,
- !connected);
+ delay, !connected);
}
port = NULL;
@@ -310,9 +310,12 @@ test_suspend_resume_edid_change(data_t *data, struct chamelium_port *port,
int alt_edid_id)
{
struct udev_monitor *mon = igt_watch_hotplug();
+ int delay = chamelium_get_suspend_resume_delay(data->chamelium);
reset_state(data, port);
+ igt_set_autoresume_delay(delay);
+
/* First plug in the port */
chamelium_port_set_edid(data->chamelium, port, edid_id);
chamelium_plug(data->chamelium, port);
--
2.13.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2017-06-26 14:00 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-26 13:59 [PATCH i-g-t 1/7] tests/chamelium: Update connector state without reprobe when possible Paul Kocialkowski
2017-06-26 13:59 ` [PATCH i-g-t 2/7] tests/chamelium: Check all connectors state for basic hotplug Paul Kocialkowski
2017-06-26 21:35 ` Lyude Paul
2017-06-26 13:59 ` [PATCH i-g-t 3/7] tests/chamelium: Use 50 ms delay to wait for connector change Paul Kocialkowski
2017-06-26 21:36 ` Lyude Paul
2017-06-26 13:59 ` [PATCH i-g-t 4/7] lib/igt_chamelium: Add support for configurable DUT suspend/resume delay Paul Kocialkowski
2017-06-26 14:25 ` Martin Peres
2017-06-26 14:33 ` Paul Kocialkowski
2017-06-26 15:15 ` Martin Peres
2017-06-26 21:14 ` Lyude Paul
2017-06-27 7:33 ` Paul Kocialkowski
2017-06-27 7:45 ` Paul Kocialkowski
2017-06-27 10:16 ` Paul Kocialkowski
2017-06-26 13:59 ` Paul Kocialkowski [this message]
2017-06-26 13:59 ` [PATCH i-g-t 6/7] tests/chamelium: Reduce the simple hotplug test toggle count for VGA Paul Kocialkowski
2017-06-26 13:59 ` [PATCH i-g-t 7/7] tests/chamelium: Disconnect connectors without extra reset Paul Kocialkowski
2017-06-26 22:17 ` Lyude Paul
2017-06-27 7:22 ` Paul Kocialkowski
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=20170626135906.32708-5-paul.kocialkowski@linux.intel.com \
--to=paul.kocialkowski@linux.intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=lyude@redhat.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).