All of lore.kernel.org
 help / color / mirror / Atom feed
From: <mikita.lipski-5C7GfCeVMHo@public.gmane.org>
To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Cc: harry.wentland-5C7GfCeVMHo@public.gmane.org,
	David Francis <David.Francis-5C7GfCeVMHo@public.gmane.org>,
	Mikita Lipski <mikita.lipski-5C7GfCeVMHo@public.gmane.org>,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Subject: [PATCH v7 02/17] drm/dp_mst: Parse FEC capability on MST ports
Date: Sat, 16 Nov 2019 17:01:13 -0500	[thread overview]
Message-ID: <20191116220128.16598-3-mikita.lipski@amd.com> (raw)
In-Reply-To: <20191116220128.16598-1-mikita.lipski-5C7GfCeVMHo@public.gmane.org>

From: David Francis <David.Francis@amd.com>

As of DP1.4, ENUM_PATH_RESOURCES returns a bit indicating
if FEC can be supported up to that point in the MST network.

The bit is the first byte of the ENUM_PATH_RESOURCES ack reply,
bottom-most bit (refer to section 2.11.9.4 of DP standard,
v1.4)

That value is needed for FEC and DSC support

Store it on drm_dp_mst_port

Reviewed-by: Lyude Paul <lyude@redhat.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: David Francis <David.Francis@amd.com>
Signed-off-by: Mikita Lipski <mikita.lipski@amd.com>
---
 drivers/gpu/drm/drm_dp_mst_topology.c | 2 ++
 include/drm/drm_dp_mst_helper.h       | 3 +++
 2 files changed, 5 insertions(+)

diff --git a/drivers/gpu/drm/drm_dp_mst_topology.c b/drivers/gpu/drm/drm_dp_mst_topology.c
index 3e7b7553cf4d..9f3604355705 100644
--- a/drivers/gpu/drm/drm_dp_mst_topology.c
+++ b/drivers/gpu/drm/drm_dp_mst_topology.c
@@ -553,6 +553,7 @@ static bool drm_dp_sideband_parse_enum_path_resources_ack(struct drm_dp_sideband
 {
 	int idx = 1;
 	repmsg->u.path_resources.port_number = (raw->msg[idx] >> 4) & 0xf;
+	repmsg->u.path_resources.fec_capable = raw->msg[idx] & 0x1;
 	idx++;
 	if (idx > raw->curlen)
 		goto fail_len;
@@ -2183,6 +2184,7 @@ static int drm_dp_send_enum_path_resources(struct drm_dp_mst_topology_mgr *mgr,
 			DRM_DEBUG_KMS("enum path resources %d: %d %d\n", txmsg->reply.u.path_resources.port_number, txmsg->reply.u.path_resources.full_payload_bw_number,
 			       txmsg->reply.u.path_resources.avail_payload_bw_number);
 			port->available_pbn = txmsg->reply.u.path_resources.avail_payload_bw_number;
+			port->fec_capable = txmsg->reply.u.path_resources.fec_capable;
 		}
 	}
 
diff --git a/include/drm/drm_dp_mst_helper.h b/include/drm/drm_dp_mst_helper.h
index 9116b2c95239..f113ae04fa88 100644
--- a/include/drm/drm_dp_mst_helper.h
+++ b/include/drm/drm_dp_mst_helper.h
@@ -108,6 +108,8 @@ struct drm_dp_mst_port {
 	 * audio-capable.
 	 */
 	bool has_audio;
+
+	bool fec_capable;
 };
 
 /**
@@ -312,6 +314,7 @@ struct drm_dp_port_number_req {
 
 struct drm_dp_enum_path_resources_ack_reply {
 	u8 port_number;
+	bool fec_capable;
 	u16 full_payload_bw_number;
 	u16 avail_payload_bw_number;
 };
-- 
2.17.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

WARNING: multiple messages have this Message-ID (diff)
From: <mikita.lipski@amd.com>
To: <amd-gfx@lists.freedesktop.org>
Cc: David Francis <David.Francis@amd.com>,
	Mikita Lipski <mikita.lipski@amd.com>,
	dri-devel@lists.freedesktop.org
Subject: [PATCH v7 02/17] drm/dp_mst: Parse FEC capability on MST ports
Date: Sat, 16 Nov 2019 17:01:13 -0500	[thread overview]
Message-ID: <20191116220128.16598-3-mikita.lipski@amd.com> (raw)
Message-ID: <20191116220113.8Nu7KfWWY4KPfR3JZl_92W_FwcASPHCxazd725UR3-8@z> (raw)
In-Reply-To: <20191116220128.16598-1-mikita.lipski@amd.com>

From: David Francis <David.Francis@amd.com>

As of DP1.4, ENUM_PATH_RESOURCES returns a bit indicating
if FEC can be supported up to that point in the MST network.

The bit is the first byte of the ENUM_PATH_RESOURCES ack reply,
bottom-most bit (refer to section 2.11.9.4 of DP standard,
v1.4)

That value is needed for FEC and DSC support

Store it on drm_dp_mst_port

Reviewed-by: Lyude Paul <lyude@redhat.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: David Francis <David.Francis@amd.com>
Signed-off-by: Mikita Lipski <mikita.lipski@amd.com>
---
 drivers/gpu/drm/drm_dp_mst_topology.c | 2 ++
 include/drm/drm_dp_mst_helper.h       | 3 +++
 2 files changed, 5 insertions(+)

diff --git a/drivers/gpu/drm/drm_dp_mst_topology.c b/drivers/gpu/drm/drm_dp_mst_topology.c
index 3e7b7553cf4d..9f3604355705 100644
--- a/drivers/gpu/drm/drm_dp_mst_topology.c
+++ b/drivers/gpu/drm/drm_dp_mst_topology.c
@@ -553,6 +553,7 @@ static bool drm_dp_sideband_parse_enum_path_resources_ack(struct drm_dp_sideband
 {
 	int idx = 1;
 	repmsg->u.path_resources.port_number = (raw->msg[idx] >> 4) & 0xf;
+	repmsg->u.path_resources.fec_capable = raw->msg[idx] & 0x1;
 	idx++;
 	if (idx > raw->curlen)
 		goto fail_len;
@@ -2183,6 +2184,7 @@ static int drm_dp_send_enum_path_resources(struct drm_dp_mst_topology_mgr *mgr,
 			DRM_DEBUG_KMS("enum path resources %d: %d %d\n", txmsg->reply.u.path_resources.port_number, txmsg->reply.u.path_resources.full_payload_bw_number,
 			       txmsg->reply.u.path_resources.avail_payload_bw_number);
 			port->available_pbn = txmsg->reply.u.path_resources.avail_payload_bw_number;
+			port->fec_capable = txmsg->reply.u.path_resources.fec_capable;
 		}
 	}
 
diff --git a/include/drm/drm_dp_mst_helper.h b/include/drm/drm_dp_mst_helper.h
index 9116b2c95239..f113ae04fa88 100644
--- a/include/drm/drm_dp_mst_helper.h
+++ b/include/drm/drm_dp_mst_helper.h
@@ -108,6 +108,8 @@ struct drm_dp_mst_port {
 	 * audio-capable.
 	 */
 	bool has_audio;
+
+	bool fec_capable;
 };
 
 /**
@@ -312,6 +314,7 @@ struct drm_dp_port_number_req {
 
 struct drm_dp_enum_path_resources_ack_reply {
 	u8 port_number;
+	bool fec_capable;
 	u16 full_payload_bw_number;
 	u16 avail_payload_bw_number;
 };
-- 
2.17.1

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

WARNING: multiple messages have this Message-ID (diff)
From: <mikita.lipski@amd.com>
To: <amd-gfx@lists.freedesktop.org>
Cc: harry.wentland@amd.com, David Francis <David.Francis@amd.com>,
	Mikita Lipski <mikita.lipski@amd.com>,
	dri-devel@lists.freedesktop.org
Subject: [PATCH v7 02/17] drm/dp_mst: Parse FEC capability on MST ports
Date: Sat, 16 Nov 2019 17:01:13 -0500	[thread overview]
Message-ID: <20191116220128.16598-3-mikita.lipski@amd.com> (raw)
Message-ID: <20191116220113.QWGV2964CC2xOxLPkj6xq0lUTpzVHgJVuBKYIpPMbzM@z> (raw)
In-Reply-To: <20191116220128.16598-1-mikita.lipski@amd.com>

From: David Francis <David.Francis@amd.com>

As of DP1.4, ENUM_PATH_RESOURCES returns a bit indicating
if FEC can be supported up to that point in the MST network.

The bit is the first byte of the ENUM_PATH_RESOURCES ack reply,
bottom-most bit (refer to section 2.11.9.4 of DP standard,
v1.4)

That value is needed for FEC and DSC support

Store it on drm_dp_mst_port

Reviewed-by: Lyude Paul <lyude@redhat.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: David Francis <David.Francis@amd.com>
Signed-off-by: Mikita Lipski <mikita.lipski@amd.com>
---
 drivers/gpu/drm/drm_dp_mst_topology.c | 2 ++
 include/drm/drm_dp_mst_helper.h       | 3 +++
 2 files changed, 5 insertions(+)

diff --git a/drivers/gpu/drm/drm_dp_mst_topology.c b/drivers/gpu/drm/drm_dp_mst_topology.c
index 3e7b7553cf4d..9f3604355705 100644
--- a/drivers/gpu/drm/drm_dp_mst_topology.c
+++ b/drivers/gpu/drm/drm_dp_mst_topology.c
@@ -553,6 +553,7 @@ static bool drm_dp_sideband_parse_enum_path_resources_ack(struct drm_dp_sideband
 {
 	int idx = 1;
 	repmsg->u.path_resources.port_number = (raw->msg[idx] >> 4) & 0xf;
+	repmsg->u.path_resources.fec_capable = raw->msg[idx] & 0x1;
 	idx++;
 	if (idx > raw->curlen)
 		goto fail_len;
@@ -2183,6 +2184,7 @@ static int drm_dp_send_enum_path_resources(struct drm_dp_mst_topology_mgr *mgr,
 			DRM_DEBUG_KMS("enum path resources %d: %d %d\n", txmsg->reply.u.path_resources.port_number, txmsg->reply.u.path_resources.full_payload_bw_number,
 			       txmsg->reply.u.path_resources.avail_payload_bw_number);
 			port->available_pbn = txmsg->reply.u.path_resources.avail_payload_bw_number;
+			port->fec_capable = txmsg->reply.u.path_resources.fec_capable;
 		}
 	}
 
diff --git a/include/drm/drm_dp_mst_helper.h b/include/drm/drm_dp_mst_helper.h
index 9116b2c95239..f113ae04fa88 100644
--- a/include/drm/drm_dp_mst_helper.h
+++ b/include/drm/drm_dp_mst_helper.h
@@ -108,6 +108,8 @@ struct drm_dp_mst_port {
 	 * audio-capable.
 	 */
 	bool has_audio;
+
+	bool fec_capable;
 };
 
 /**
@@ -312,6 +314,7 @@ struct drm_dp_port_number_req {
 
 struct drm_dp_enum_path_resources_ack_reply {
 	u8 port_number;
+	bool fec_capable;
 	u16 full_payload_bw_number;
 	u16 avail_payload_bw_number;
 };
-- 
2.17.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

  parent reply	other threads:[~2019-11-16 22:01 UTC|newest]

Thread overview: 65+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-16 22:01 [PATCH v7 00/17] DSC MST support for DRM and AMDGPU mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01 ` mikita.lipski
2019-11-16 22:01 ` mikita.lipski
2019-11-16 22:01 ` [PATCH v7 01/17] drm/dp_mst: Add PBN calculation for DSC modes mikita.lipski
2019-11-16 22:01   ` mikita.lipski
2019-11-16 22:01   ` mikita.lipski
2019-11-16 22:01 ` [PATCH v7 05/17] drm/dp_mst: Add helpers for MST DSC and virtual DPCD aux mikita.lipski
2019-11-16 22:01   ` mikita.lipski
2019-11-16 22:01   ` mikita.lipski
     [not found] ` <20191116220128.16598-1-mikita.lipski-5C7GfCeVMHo@public.gmane.org>
2019-11-16 22:01   ` mikita.lipski-5C7GfCeVMHo [this message]
2019-11-16 22:01     ` [PATCH v7 02/17] drm/dp_mst: Parse FEC capability on MST ports mikita.lipski
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01   ` [PATCH v7 03/17] drm/dp_mst: Add MST support to DP DPCD R/W functions mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01   ` [PATCH v7 04/17] drm/dp_mst: Fill branch->num_ports mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01   ` [PATCH v7 06/17] drm/dp_mst: Add new quirk for Synaptics MST hubs mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01   ` [PATCH v7 07/17] drm/amd/display: Initialize DSC PPS variables to 0 mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01   ` [PATCH v7 08/17] drm/amd/display: Validate DSC caps on MST endpoints mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01   ` [PATCH v7 09/17] drm/amd/display: Write DSC enable to MST DPCD mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01   ` [PATCH v7 10/17] drm/dp_mst: Manually overwrite PBN divider for calculating timeslots mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01     ` mikita.lipski
     [not found]     ` <20191116220128.16598-11-mikita.lipski-5C7GfCeVMHo@public.gmane.org>
2019-11-26 15:06       ` Leo
2019-11-26 15:06         ` Leo
2019-11-16 22:01   ` [PATCH v7 11/17] drm/dp_mst: Add DSC enablement helpers to DRM mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01     ` mikita.lipski
     [not found]     ` <20191116220128.16598-12-mikita.lipski-5C7GfCeVMHo@public.gmane.org>
2019-11-26 15:24       ` Leo
2019-11-26 15:24         ` Leo
     [not found]         ` <fe56a601-777d-f8db-c229-f155a162f100-5C7GfCeVMHo@public.gmane.org>
2019-11-26 15:27           ` Leo
2019-11-26 15:27             ` Leo
2019-11-26 15:32           ` Mikita Lipski
2019-11-26 15:32             ` Mikita Lipski
2019-11-16 22:01   ` [PATCH v7 12/17] drm/dp_mst: Add branch bandwidth validation to MST atomic check mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01     ` mikita.lipski
     [not found]     ` <20191116220128.16598-13-mikita.lipski-5C7GfCeVMHo@public.gmane.org>
2019-11-26 19:55       ` Leo
2019-11-26 19:55         ` Leo
2019-11-26 19:55         ` Leo
2019-11-16 22:01   ` [PATCH v7 13/17] drm/dp_mst: Add helper to trigger modeset on affected DSC MST CRTCs mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01   ` [PATCH v7 14/17] drm/amd/display: Add PBN per slot calculation for DSC mikita.lipski-5C7GfCeVMHo
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01     ` mikita.lipski
2019-11-16 22:01 ` [PATCH v7 15/17] drm/amd/display: MST DSC compute fair share mikita.lipski
2019-11-16 22:01   ` mikita.lipski
2019-11-16 22:01   ` mikita.lipski
2019-11-16 22:01 ` [PATCH v7 16/17] drm/amd/display: Recalculate VCPI slots for new DSC connectors mikita.lipski
2019-11-16 22:01   ` mikita.lipski
2019-11-16 22:01   ` mikita.lipski
2019-11-16 22:01 ` [PATCH v7 17/17] drm/amd/display: Trigger modesets on MST " mikita.lipski
2019-11-16 22:01   ` mikita.lipski
2019-11-16 22:01   ` mikita.lipski

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=20191116220128.16598-3-mikita.lipski@amd.com \
    --to=mikita.lipski-5c7gfcevmho@public.gmane.org \
    --cc=David.Francis-5C7GfCeVMHo@public.gmane.org \
    --cc=amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    --cc=dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    --cc=harry.wentland-5C7GfCeVMHo@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 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.