From: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
To: amd-gfx@lists.freedesktop.org
Cc: Aric Cyr <Aric.Cyr@amd.com>,
Wesley Chalmers <Wesley.Chalmers@amd.com>,
Eryk.Brol@amd.com, Sunpeng.Li@amd.com, Harry.Wentland@amd.com,
qingqing.zhuo@amd.com, Rodrigo.Siqueira@amd.com,
roman.li@amd.com, Aurabindo.Pillai@amd.com,
Bhawanpreet.Lakha@amd.com, bindu.r@amd.com
Subject: [PATCH 08/21] drm/amd/display: New path for enabling DPG
Date: Fri, 8 Jan 2021 16:49:54 -0500 [thread overview]
Message-ID: <20210108215007.851249-9-Rodrigo.Siqueira@amd.com> (raw)
In-Reply-To: <20210108215007.851249-1-Rodrigo.Siqueira@amd.com>
From: Wesley Chalmers <Wesley.Chalmers@amd.com>
[WHY]
We want to make enabling test pattern a part of the stream update code
path. This change is the first step towards that goal.
Signed-off-by: Wesley Chalmers <Wesley.Chalmers@amd.com>
Reviewed-by: Aric Cyr <Aric.Cyr@amd.com>
Acked-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
---
drivers/gpu/drm/amd/display/dc/core/dc.c | 12 ++++++++++++
drivers/gpu/drm/amd/display/dc/dc_stream.h | 11 +++++++++++
2 files changed, 23 insertions(+)
diff --git a/drivers/gpu/drm/amd/display/dc/core/dc.c b/drivers/gpu/drm/amd/display/dc/core/dc.c
index 8f1cadb823c7..7801b44cfaec 100644
--- a/drivers/gpu/drm/amd/display/dc/core/dc.c
+++ b/drivers/gpu/drm/amd/display/dc/core/dc.c
@@ -2265,6 +2265,9 @@ static void copy_stream_update_to_stream(struct dc *dc,
if (update->dither_option)
stream->dither_option = *update->dither_option;
+
+ if (update->pending_test_pattern)
+ stream->test_pattern = *update->pending_test_pattern;
/* update current stream with writeback info */
if (update->wb_update) {
int i;
@@ -2361,6 +2364,15 @@ static void commit_planes_do_stream_update(struct dc *dc,
}
}
+ if (stream_update->pending_test_pattern) {
+ dc_link_dp_set_test_pattern(stream->link,
+ stream->test_pattern.type,
+ stream->test_pattern.color_space,
+ stream->test_pattern.p_link_settings,
+ stream->test_pattern.p_custom_pattern,
+ stream->test_pattern.cust_pattern_size);
+ }
+
/* Full fe update*/
if (update_type == UPDATE_TYPE_FAST)
continue;
diff --git a/drivers/gpu/drm/amd/display/dc/dc_stream.h b/drivers/gpu/drm/amd/display/dc/dc_stream.h
index b7910976b81a..80b67b860091 100644
--- a/drivers/gpu/drm/amd/display/dc/dc_stream.h
+++ b/drivers/gpu/drm/amd/display/dc/dc_stream.h
@@ -130,6 +130,14 @@ union stream_update_flags {
uint32_t raw;
};
+struct test_pattern {
+ enum dp_test_pattern type;
+ enum dp_test_pattern_color_space color_space;
+ struct link_training_settings const *p_link_settings;
+ unsigned char const *p_custom_pattern;
+ unsigned int cust_pattern_size;
+};
+
struct dc_stream_state {
// sink is deprecated, new code should not reference
// this pointer
@@ -227,6 +235,8 @@ struct dc_stream_state {
uint32_t stream_id;
bool is_dsc_enabled;
+
+ struct test_pattern test_pattern;
union stream_update_flags update_flags;
};
@@ -261,6 +271,7 @@ struct dc_stream_update {
struct dc_dsc_config *dsc_config;
struct dc_transfer_func *func_shaper;
struct dc_3dlut *lut3d_func;
+ struct test_pattern *pending_test_pattern;
};
bool dc_is_stream_unchanged(
--
2.25.1
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
next prev parent reply other threads:[~2021-01-08 21:50 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-08 21:49 [PATCH 00/21] DC Patches January 08, 2021 Rodrigo Siqueira
2021-01-08 21:49 ` [PATCH 01/21] drm/amd/display: 3.2.117 Rodrigo Siqueira
2021-01-08 21:49 ` [PATCH 02/21] drm/amd/display: NULL pointer hang Rodrigo Siqueira
2021-01-08 21:49 ` [PATCH 03/21] drm/amd/display: Initialize stack variable Rodrigo Siqueira
2021-01-08 21:49 ` [PATCH 04/21] drm/amd/display: Separate fec debug flag and monitor patch Rodrigo Siqueira
2021-01-08 21:49 ` [PATCH 05/21] drm/amd/display: HUBP_IN_BLANK for DCN30 Rodrigo Siqueira
2021-01-08 21:49 ` [PATCH 06/21] drm/amd/display: Remove HUBP_DISABLE from default Rodrigo Siqueira
2021-01-10 23:12 ` Rodrigo Siqueira
2021-01-08 21:49 ` [PATCH 07/21] drm/amd/display: Unblank hubp based on plane visibility Rodrigo Siqueira
2021-01-08 21:49 ` Rodrigo Siqueira [this message]
2021-01-08 21:49 ` [PATCH 09/21] drm/amd/display: removed unnecessary check when dpp clock increasing Rodrigo Siqueira
2021-01-08 21:49 ` [PATCH 10/21] drm/amd/display: doesn't reprogram AMD OUI Rodrigo Siqueira
2021-01-08 21:49 ` [PATCH 11/21] drm/amd/display: Remove unused P010 debug flag Rodrigo Siqueira
2021-01-08 21:49 ` [PATCH 12/21] drm/amd/display: implement T12 compliance Rodrigo Siqueira
2021-01-08 21:49 ` [PATCH 13/21] drm/amd/display: fix seamless boot stream adding algorithm Rodrigo Siqueira
2021-01-08 21:50 ` [PATCH 14/21] drm/amd/display: Fix assert being hit with GAMCOR memory shut down Rodrigo Siqueira
2021-01-08 21:50 ` [PATCH 15/21] drm/amd/display: New sequence for HUBP blank Rodrigo Siqueira
2021-01-08 21:50 ` [PATCH 16/21] drm/amd/display: enable HUBP blank behaviour Rodrigo Siqueira
2021-01-08 21:50 ` [PATCH 17/21] drm/amd/display: Add a missing DCN3.01 API mapping Rodrigo Siqueira
2021-01-08 21:50 ` [PATCH 18/21] drm/amd/display: 3.2.118 Rodrigo Siqueira
2021-01-08 21:50 ` [PATCH 19/21] drm/amd/display: Revert patch causing black screen Rodrigo Siqueira
2021-01-08 21:50 ` [PATCH 20/21] drm/amd/display: disable dcn10 pipe split by default Rodrigo Siqueira
2021-01-08 21:50 ` [PATCH 21/21] drm/amd/display: change SMU repsonse timeout to 2s Rodrigo Siqueira
2021-01-08 22:12 ` [PATCH 00/21] DC Patches January 08, 2021 Rodrigo Siqueira
2021-01-08 22:52 ` Wheeler, Daniel
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=20210108215007.851249-9-Rodrigo.Siqueira@amd.com \
--to=rodrigo.siqueira@amd.com \
--cc=Aric.Cyr@amd.com \
--cc=Aurabindo.Pillai@amd.com \
--cc=Bhawanpreet.Lakha@amd.com \
--cc=Eryk.Brol@amd.com \
--cc=Harry.Wentland@amd.com \
--cc=Sunpeng.Li@amd.com \
--cc=Wesley.Chalmers@amd.com \
--cc=amd-gfx@lists.freedesktop.org \
--cc=bindu.r@amd.com \
--cc=qingqing.zhuo@amd.com \
--cc=roman.li@amd.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