From: Lyude <lyude-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org,
igt-dev-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Subject: [PATCH i-g-t v3 4/5] lib/igt_kms: Hook up connector dithering prop
Date: Fri, 17 Apr 2020 17:10:24 -0400 [thread overview]
Message-ID: <20200417211025.109574-5-lyude@redhat.com> (raw)
In-Reply-To: <20200417211025.109574-1-lyude-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
From: Lyude Paul <lyude-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
Nvidia display hardware provides a set of flexible dithering options for
CRTCs. This dithering is actually noticeable in the CRC output for all
available tap points, and can be seen as CRC values for identical frames
cycling between either 2 or 4 values repeatedly (each one of these
values is a different dithering phase applied to the source output). Of
course, this is very likely to break tests using CRC readback since we
don't expect the CRC to change if the source content hasn't changed.
So, hook up support for configuring the dithering property and reset it
to off from igt_display_reset() when applicable.
Signed-off-by: Lyude Paul <lyude-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
---
lib/igt_kms.c | 6 ++++++
lib/igt_kms.h | 1 +
2 files changed, 7 insertions(+)
diff --git a/lib/igt_kms.c b/lib/igt_kms.c
index e9621e7e..d45adfaf 100644
--- a/lib/igt_kms.c
+++ b/lib/igt_kms.c
@@ -421,6 +421,7 @@ const char * const igt_connector_prop_names[IGT_NUM_CONNECTOR_PROPS] = {
[IGT_CONNECTOR_LINK_STATUS] = "link-status",
[IGT_CONNECTOR_MAX_BPC] = "max bpc",
[IGT_CONNECTOR_HDR_OUTPUT_METADATA] = "HDR_OUTPUT_METADATA",
+ [IGT_CONNECTOR_DITHERING_MODE] = "dithering mode",
};
/*
@@ -1802,6 +1803,10 @@ static void igt_output_reset(igt_output_t *output)
if (igt_output_has_prop(output, IGT_CONNECTOR_HDR_OUTPUT_METADATA))
igt_output_set_prop_value(output,
IGT_CONNECTOR_HDR_OUTPUT_METADATA, 0);
+
+ if (igt_output_has_prop(output, IGT_CONNECTOR_DITHERING_MODE))
+ igt_output_set_prop_enum(output, IGT_CONNECTOR_DITHERING_MODE,
+ "off");
}
/**
@@ -1816,6 +1821,7 @@ static void igt_output_reset(igt_output_t *output)
* - %IGT_CONNECTOR_BROADCAST_RGB (if applicable)
* %IGT_CONNECTOR_CONTENT_PROTECTION (if applicable)
* %IGT_CONNECTOR_HDR_OUTPUT_METADATA (if applicable)
+ * - %IGT_CONNECTOR_DITHERING_MODE (if applicable)
* - igt_output_override_mode() to default.
*
* For pipes:
diff --git a/lib/igt_kms.h b/lib/igt_kms.h
index adca59ac..4899e765 100644
--- a/lib/igt_kms.h
+++ b/lib/igt_kms.h
@@ -127,6 +127,7 @@ enum igt_atomic_connector_properties {
IGT_CONNECTOR_LINK_STATUS,
IGT_CONNECTOR_MAX_BPC,
IGT_CONNECTOR_HDR_OUTPUT_METADATA,
+ IGT_CONNECTOR_DITHERING_MODE,
IGT_NUM_CONNECTOR_PROPS
};
--
2.25.1
next prev parent reply other threads:[~2020-04-17 21:10 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-17 21:10 [PATCH i-g-t v3 0/5] Add nouveau-crc tests Lyude
[not found] ` <20200417211025.109574-1-lyude-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2020-04-17 21:10 ` [PATCH i-g-t v3 1/5] lib/igt_core: Fix igt_assert_fd() documentation Lyude
[not found] ` <20200417211025.109574-2-lyude-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2020-04-20 9:29 ` [igt-dev] " Petri Latvala
2020-04-17 21:10 ` [PATCH i-g-t v3 2/5] lib/igt_core: Add igt_require_fd() Lyude
[not found] ` <20200417211025.109574-3-lyude-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2020-04-20 9:29 ` [igt-dev] " Petri Latvala
2020-04-17 21:10 ` [PATCH i-g-t v3 3/5] lib/igt_debugfs: Add igt_debugfs_pipe_dir() Lyude
[not found] ` <20200417211025.109574-4-lyude-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2020-08-18 21:01 ` [i-g-t, v3, " Jeremy Cline
2020-04-17 21:10 ` Lyude [this message]
[not found] ` <20200417211025.109574-5-lyude-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2020-08-18 21:18 ` [i-g-t, v3, 4/5] lib/igt_kms: Hook up connector dithering prop Jeremy Cline
2020-04-17 21:10 ` [PATCH i-g-t v3 5/5] tests: Add nouveau-crc tests Lyude
[not found] ` <20200417211025.109574-6-lyude-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2020-08-18 21:00 ` [PATCH i-g-t v4] " Lyude
[not found] ` <20200818210051.28705-1-lyude-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2020-09-28 21:36 ` [igt-dev] " Jeremy Cline
2020-09-29 16:13 ` Lyude Paul
[not found] ` <b5673893f45f4bb72a90ca55d45100391a49c8e8.camel-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2020-09-29 17:42 ` Jeremy Cline
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=20200417211025.109574-5-lyude@redhat.com \
--to=lyude-h+wxahxf7alqt0dzr+alfa@public.gmane.org \
--cc=igt-dev-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
--cc=nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.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 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).