[RFC 07/13] drm/dp: Read AUX read interval from DPCD

Thierry Reding thierry.reding at gmail.com
Wed Aug 12 08:06:35 PDT 2015


From: Thierry Reding <treding at nvidia.com>

Store the AUX read interval from DPCD, so that it can be used to wait
for the durations given in the specification during link training.

Signed-off-by: Thierry Reding <treding at nvidia.com>
---
 drivers/gpu/drm/drm_dp_helper.c | 3 +++
 include/drm/drm_dp_helper.h     | 1 +
 2 files changed, 4 insertions(+)

diff --git a/drivers/gpu/drm/drm_dp_helper.c b/drivers/gpu/drm/drm_dp_helper.c
index c711b690508b..9d6ef0576abc 100644
--- a/drivers/gpu/drm/drm_dp_helper.c
+++ b/drivers/gpu/drm/drm_dp_helper.c
@@ -351,6 +351,9 @@ int drm_dp_link_probe(struct drm_dp_aux *aux, struct drm_dp_link *link)
 		}
 	}
 
+	/* DP_TRAINING_AUX_RD_INTERVAL is in units of 4 milliseconds */
+	link->aux_rd_interval = values[14] * 4000;
+
 	return 0;
 }
 EXPORT_SYMBOL(drm_dp_link_probe);
diff --git a/include/drm/drm_dp_helper.h b/include/drm/drm_dp_helper.h
index f9e7f484a225..1fda4643af1f 100644
--- a/include/drm/drm_dp_helper.h
+++ b/include/drm/drm_dp_helper.h
@@ -753,6 +753,7 @@ struct drm_dp_link {
 	unsigned int rate;
 	unsigned int num_lanes;
 	unsigned long capabilities;
+	unsigned long aux_rd_interval;
 };
 
 int drm_dp_link_probe(struct drm_dp_aux *aux, struct drm_dp_link *link);
-- 
2.4.5



More information about the dri-devel mailing list