Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Suraj Kandpal <suraj.kandpal@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: santhosh.reddy.guddati@intel.com,
	Suraj Kandpal <suraj.kandpal@intel.com>
Subject: [PATCH i-g-t] test/kms_content_protection: Account for reauthetication in LIC
Date: Tue,  3 Dec 2024 11:45:19 +0530	[thread overview]
Message-ID: <20241203061519.2121105-1-suraj.kandpal@intel.com> (raw)

During LIC the link may fail due to a variety of reasons but this
does not reflect a problem with HDCP. It becomes a problem only when
we are not able to recover from the Link Integrity Failure.
Add a check to see if CP property is CP_DESIRED and if so give it time
to reauthenticate and fail only if this reauthentication does not
happen.

--v2
-Add debug statement [Santhosh]
-Add closes tag [Santhosh]

Closes: https://gitlab.freedesktop.org/drm/xe/kernel/-/issues/3508
Signed-off-by: Suraj Kandpal <suraj.kandpal@intel.com>
---
 tests/kms_content_protection.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/tests/kms_content_protection.c b/tests/kms_content_protection.c
index 59dca54df..04dff7a05 100644
--- a/tests/kms_content_protection.c
+++ b/tests/kms_content_protection.c
@@ -376,9 +376,17 @@ static bool igt_pipe_is_free(igt_display_t *display, enum pipe pipe)
 static void test_cp_lic(igt_output_t *output)
 {
 	bool ret;
+	uint64_t val;
 
 	/* Wait for 4Secs (min 2 cycles of Link Integrity Check) */
 	ret = wait_for_prop_value(output, CP_DESIRED, LIC_PERIOD_MSEC);
+	val = igt_output_get_prop(output,
+				  IGT_CONNECTOR_CONTENT_PROTECTION);
+	if (val == CP_DESIRED) {
+		igt_debug("Link Integrity Check failed, waiting for reauthentication\n");
+		ret = wait_for_prop_value(output, CP_DESIRED, LIC_PERIOD_MSEC);
+	}
+
 	igt_assert_f(!ret, "Content Protection LIC Failed\n");
 }
 
-- 
2.34.1


             reply	other threads:[~2024-12-03  6:15 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-03  6:15 Suraj Kandpal [this message]
2024-12-03  6:42 ` ✓ Xe.CI.BAT: success for test/kms_content_protection: Account for reauthetication in LIC (rev2) Patchwork
2024-12-03  6:53 ` ✗ i915.CI.BAT: failure " Patchwork
2024-12-03  7:33 ` ✗ Xe.CI.Full: " Patchwork
2024-12-04  5:11 ` [PATCH i-g-t] test/kms_content_protection: Account for reauthetication in LIC Reddy Guddati, Santhosh
2024-12-09 14:31 ` ✓ i915.CI.BAT: success for test/kms_content_protection: Account for reauthetication in LIC (rev2) Patchwork
2024-12-09 14:35 ` Patchwork
2024-12-09 16:39 ` ✗ i915.CI.Full: failure " Patchwork
  -- strict thread matches above, loose matches on Subject: below --
2024-11-28  9:14 [PATCH i-g-t] test/kms_content_protection: Account for reauthetication in LIC Suraj Kandpal
2024-12-03  4:41 ` Reddy Guddati, Santhosh

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=20241203061519.2121105-1-suraj.kandpal@intel.com \
    --to=suraj.kandpal@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=santhosh.reddy.guddati@intel.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