search for: dp_max_downstream_ports

Displaying 20 results from an estimated 24 matches for "dp_max_downstream_ports".

2020 Aug 19
3
[RFC 13/20] drm/i915/dp: Extract drm_dp_downstream_read_info()
...urns: 0 if either the downstream port info was read successfully or > + * there was no downstream info to read, or a negative error code otherwise. > + */ > +int drm_dp_downstream_read_info(struct drm_dp_aux *aux, > + const u8 dpcd[DP_RECEIVER_CAP_SIZE], > + u8 downstream_ports[DP_MAX_DOWNSTREAM_PORTS]) > +{ > + int ret; > + u8 len; > + > + memset(downstream_ports, 0, DP_MAX_DOWNSTREAM_PORTS); > + > + /* No downstream info to read */ > + if (!drm_dp_is_branch(dpcd) || > + dpcd[DP_DPCD_REV] < DP_DPCD_REV_10 || > + !(dpcd[DP_DOWNSTREAMPORT_PRESENT] & DP...
2020 Apr 24
2
[PATCH 3/5] drm/nouveau: utilize subconnector property for DP
...veau_dp.c index 2674f15..85eac85 100644 --- a/drivers/gpu/drm/nouveau/nouveau_dp.c +++ b/drivers/gpu/drm/nouveau/nouveau_dp.c @@ -62,6 +62,7 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) struct nouveau_drm *drm = nouveau_drm(dev); struct nvkm_i2c_aux *aux; u8 dpcd[8]; + u8 port_cap[DP_MAX_DOWNSTREAM_PORTS] = {}; int ret; aux = nv_encoder->aux; @@ -72,6 +73,14 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) if (ret) return ret; + if (dpcd[DP_DPCD_REV] > 0x10) { + ret = nvkm_rdaux(aux, DP_DOWNSTREAM_PORT_0, + port_cap, DP_MAX_DOWNSTREAM_PORTS); + if (ret) + memset(p...
2019 Aug 26
2
[PATCH v3 5/7] drm/nouveau: utilize subconnector property for DP
...index 2674f1587457..85eac853e3f8 100644 --- a/drivers/gpu/drm/nouveau/nouveau_dp.c +++ b/drivers/gpu/drm/nouveau/nouveau_dp.c @@ -62,6 +62,7 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) struct nouveau_drm *drm = nouveau_drm(dev); struct nvkm_i2c_aux *aux; u8 dpcd[8]; + u8 port_cap[DP_MAX_DOWNSTREAM_PORTS] = {}; int ret; aux = nv_encoder->aux; @@ -72,6 +73,14 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) if (ret) return ret; + if (dpcd[DP_DPCD_REV] > 0x10) { + ret = nvkm_rdaux(aux, DP_DOWNSTREAM_PORT_0, + port_cap, DP_MAX_DOWNSTREAM_PORTS); + if (ret) + memset(p...
2020 Aug 20
2
[RFC 13/20] drm/i915/dp: Extract drm_dp_downstream_read_info()
...or > > > + * there was no downstream info to read, or a negative error code > > > otherwise. > > > + */ > > > +int drm_dp_downstream_read_info(struct drm_dp_aux *aux, > > > + const u8 dpcd[DP_RECEIVER_CAP_SIZE], > > > + u8 downstream_ports[DP_MAX_DOWNSTREAM_PORTS]) > > > +{ > > > + int ret; > > > + u8 len; > > > + > > > + memset(downstream_ports, 0, DP_MAX_DOWNSTREAM_PORTS); > > > + > > > + /* No downstream info to read */ > > > + if (!drm_dp_is_branch(dpcd) || > > > + dpcd...
2020 Aug 19
0
[RFC 13/20] drm/i915/dp: Extract drm_dp_downstream_read_info()
...rt info was read successfully or > > + * there was no downstream info to read, or a negative error code > > otherwise. > > + */ > > +int drm_dp_downstream_read_info(struct drm_dp_aux *aux, > > + const u8 dpcd[DP_RECEIVER_CAP_SIZE], > > + u8 downstream_ports[DP_MAX_DOWNSTREAM_PORTS]) > > +{ > > + int ret; > > + u8 len; > > + > > + memset(downstream_ports, 0, DP_MAX_DOWNSTREAM_PORTS); > > + > > + /* No downstream info to read */ > > + if (!drm_dp_is_branch(dpcd) || > > + dpcd[DP_DPCD_REV] < DP_DPCD_REV_10 || > &gt...
2020 Aug 11
0
[RFC 13/20] drm/i915/dp: Extract drm_dp_downstream_read_info()
...port info in + * + * Returns: 0 if either the downstream port info was read successfully or + * there was no downstream info to read, or a negative error code otherwise. + */ +int drm_dp_downstream_read_info(struct drm_dp_aux *aux, + const u8 dpcd[DP_RECEIVER_CAP_SIZE], + u8 downstream_ports[DP_MAX_DOWNSTREAM_PORTS]) +{ + int ret; + u8 len; + + memset(downstream_ports, 0, DP_MAX_DOWNSTREAM_PORTS); + + /* No downstream info to read */ + if (!drm_dp_is_branch(dpcd) || + dpcd[DP_DPCD_REV] < DP_DPCD_REV_10 || + !(dpcd[DP_DOWNSTREAMPORT_PRESENT] & DP_DWN_STRM_PORT_PRESENT)) + return 0; + + len = (d...
2020 Aug 20
0
[RFC v2 13/20] drm/i915/dp: Extract drm_dp_downstream_read_info()
...port info in + * + * Returns: 0 if either the downstream port info was read successfully or + * there was no downstream info to read, or a negative error code otherwise. + */ +int drm_dp_downstream_read_info(struct drm_dp_aux *aux, + const u8 dpcd[DP_RECEIVER_CAP_SIZE], + u8 downstream_ports[DP_MAX_DOWNSTREAM_PORTS]) +{ + int ret; + u8 len; + + memset(downstream_ports, 0, DP_MAX_DOWNSTREAM_PORTS); + + /* No downstream info to read */ + if (!drm_dp_is_branch(dpcd) || + dpcd[DP_DPCD_REV] < DP_DPCD_REV_10 || + !(dpcd[DP_DOWNSTREAMPORT_PRESENT] & DP_DWN_STRM_PORT_PRESENT)) + return 0; + + len = dr...
2019 Jul 15
1
[PATCH v2 5/6] drm/nouveau: utilize subconnector property for DP
...index 0d052e1660f8..7a87b0f808a7 100644 --- a/drivers/gpu/drm/nouveau/nouveau_dp.c +++ b/drivers/gpu/drm/nouveau/nouveau_dp.c @@ -63,6 +63,7 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) struct nouveau_drm *drm = nouveau_drm(dev); struct nvkm_i2c_aux *aux; u8 dpcd[8]; + u8 port_cap[DP_MAX_DOWNSTREAM_PORTS] = {0}; int ret; aux = nv_encoder->aux; @@ -73,6 +74,14 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) if (ret) return ret; + if (dpcd[DP_DPCD_REV] > 0x10) { + ret = nvkm_rdaux(aux, DP_DOWNSTREAM_PORT_0, + port_cap, DP_MAX_DOWNSTREAM_PORTS); + if (ret) + memset(...
2020 Aug 21
0
[RFC 13/20] drm/i915/dp: Extract drm_dp_downstream_read_info()
...info to read, or a negative error code > > > > otherwise. > > > > + */ > > > > +int drm_dp_downstream_read_info(struct drm_dp_aux *aux, > > > > + const u8 dpcd[DP_RECEIVER_CAP_SIZE], > > > > + u8 > > > > downstream_ports[DP_MAX_DOWNSTREAM_PORTS]) > > > > +{ > > > > + int ret; > > > > + u8 len; > > > > + > > > > + memset(downstream_ports, 0, DP_MAX_DOWNSTREAM_PORTS); > > > > + > > > > + /* No downstream info to read */ > > > > + if (!drm_dp_is_b...
2020 Aug 26
0
[PATCH v5 13/20] drm/i915/dp: Extract drm_dp_read_downstream_info()
...eam_max_bpc() + * + * Returns: 0 if either the downstream port info was read successfully or + * there was no downstream info to read, or a negative error code otherwise. + */ +int drm_dp_read_downstream_info(struct drm_dp_aux *aux, + const u8 dpcd[DP_RECEIVER_CAP_SIZE], + u8 downstream_ports[DP_MAX_DOWNSTREAM_PORTS]) +{ + int ret; + u8 len; + + memset(downstream_ports, 0, DP_MAX_DOWNSTREAM_PORTS); + + /* No downstream info to read */ + if (!drm_dp_is_branch(dpcd) || + dpcd[DP_DPCD_REV] < DP_DPCD_REV_10 || + !(dpcd[DP_DOWNSTREAMPORT_PRESENT] & DP_DWN_STRM_PORT_PRESENT)) + return 0; + + len = dr...
2019 Jul 25
0
[PATCH v3 5/5] drm/nouveau: utilize subconnector property for DP
...index 0d052e1660f8..dce77830be39 100644 --- a/drivers/gpu/drm/nouveau/nouveau_dp.c +++ b/drivers/gpu/drm/nouveau/nouveau_dp.c @@ -63,6 +63,7 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) struct nouveau_drm *drm = nouveau_drm(dev); struct nvkm_i2c_aux *aux; u8 dpcd[8]; + u8 port_cap[DP_MAX_DOWNSTREAM_PORTS] = {}; int ret; aux = nv_encoder->aux; @@ -73,6 +74,14 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) if (ret) return ret; + if (dpcd[DP_DPCD_REV] > 0x10) { + ret = nvkm_rdaux(aux, DP_DOWNSTREAM_PORT_0, + port_cap, DP_MAX_DOWNSTREAM_PORTS); + if (ret) + memset(p...
2019 Aug 29
0
[PATCH v4 5/7] drm/nouveau: utilize subconnector property for DP
...index 2674f1587457..85eac853e3f8 100644 --- a/drivers/gpu/drm/nouveau/nouveau_dp.c +++ b/drivers/gpu/drm/nouveau/nouveau_dp.c @@ -62,6 +62,7 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) struct nouveau_drm *drm = nouveau_drm(dev); struct nvkm_i2c_aux *aux; u8 dpcd[8]; + u8 port_cap[DP_MAX_DOWNSTREAM_PORTS] = {}; int ret; aux = nv_encoder->aux; @@ -72,6 +73,14 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) if (ret) return ret; + if (dpcd[DP_DPCD_REV] > 0x10) { + ret = nvkm_rdaux(aux, DP_DOWNSTREAM_PORT_0, + port_cap, DP_MAX_DOWNSTREAM_PORTS); + if (ret) + memset(p...
2020 Apr 01
0
[PATCH 3/5] drm/nouveau: utilize subconnector property for DP
...veau_dp.c index 2674f15..85eac85 100644 --- a/drivers/gpu/drm/nouveau/nouveau_dp.c +++ b/drivers/gpu/drm/nouveau/nouveau_dp.c @@ -62,6 +62,7 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) struct nouveau_drm *drm = nouveau_drm(dev); struct nvkm_i2c_aux *aux; u8 dpcd[8]; + u8 port_cap[DP_MAX_DOWNSTREAM_PORTS] = {}; int ret; aux = nv_encoder->aux; @@ -72,6 +73,14 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) if (ret) return ret; + if (dpcd[DP_DPCD_REV] > 0x10) { + ret = nvkm_rdaux(aux, DP_DOWNSTREAM_PORT_0, + port_cap, DP_MAX_DOWNSTREAM_PORTS); + if (ret) + memset(p...
2020 Aug 16
0
[v3] drm/nouveau: utilize subconnector property for DP
...veau_dp.c index 8a0f799..3eff884 100644 --- a/drivers/gpu/drm/nouveau/nouveau_dp.c +++ b/drivers/gpu/drm/nouveau/nouveau_dp.c @@ -62,6 +62,7 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) struct nouveau_drm *drm = nouveau_drm(dev); struct nvkm_i2c_aux *aux; u8 dpcd[8]; + u8 port_cap[DP_MAX_DOWNSTREAM_PORTS] = {}; int ret; aux = nv_encoder->aux; @@ -72,6 +73,14 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) if (ret) return ret; + if (dpcd[DP_DPCD_REV] > 0x10) { + ret = nvkm_rdaux(aux, DP_DOWNSTREAM_PORT_0, + port_cap, DP_MAX_DOWNSTREAM_PORTS); + if (ret) + memset(p...
2020 Apr 07
0
[PATCH 3/5] drm/nouveau: utilize subconnector property for DP
...veau_dp.c index 2674f15..85eac85 100644 --- a/drivers/gpu/drm/nouveau/nouveau_dp.c +++ b/drivers/gpu/drm/nouveau/nouveau_dp.c @@ -62,6 +62,7 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) struct nouveau_drm *drm = nouveau_drm(dev); struct nvkm_i2c_aux *aux; u8 dpcd[8]; + u8 port_cap[DP_MAX_DOWNSTREAM_PORTS] = {}; int ret; aux = nv_encoder->aux; @@ -72,6 +73,14 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) if (ret) return ret; + if (dpcd[DP_DPCD_REV] > 0x10) { + ret = nvkm_rdaux(aux, DP_DOWNSTREAM_PORT_0, + port_cap, DP_MAX_DOWNSTREAM_PORTS); + if (ret) + memset(p...
2019 Aug 26
0
[PATCH v3 5/7] drm/nouveau: utilize subconnector property for DP
...gpu/drm/nouveau/nouveau_dp.c > +++ b/drivers/gpu/drm/nouveau/nouveau_dp.c > @@ -62,6 +62,7 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) > struct nouveau_drm *drm = nouveau_drm(dev); > struct nvkm_i2c_aux *aux; > u8 dpcd[8]; > + u8 port_cap[DP_MAX_DOWNSTREAM_PORTS] = {}; > int ret; > > aux = nv_encoder->aux; > @@ -72,6 +73,14 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) > if (ret) > return ret; > > + if (dpcd[DP_DPCD_REV] > 0x10) { > + ret = nvkm_rdaux(au...
2019 Aug 28
2
[PATCH v3 5/7] drm/nouveau: utilize subconnector property for DP
...gt; > +++ b/drivers/gpu/drm/nouveau/nouveau_dp.c > > @@ -62,6 +62,7 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) > > struct nouveau_drm *drm = nouveau_drm(dev); > > struct nvkm_i2c_aux *aux; > > u8 dpcd[8]; > > + u8 port_cap[DP_MAX_DOWNSTREAM_PORTS] = {}; > > int ret; > > > > aux = nv_encoder->aux; > > @@ -72,6 +73,14 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) > > if (ret) > > return ret; > > > > + if (dpcd[DP_DPCD_REV] > 0x10) {...
2019 Jul 15
0
[PATCH v2 5/6] drm/nouveau: utilize subconnector property for DP
...0644 > --- a/drivers/gpu/drm/nouveau/nouveau_dp.c > +++ b/drivers/gpu/drm/nouveau/nouveau_dp.c > @@ -63,6 +63,7 @@ nouveau_dp_detect(struct nouveau_encoder *nv_encoder) > struct nouveau_drm *drm = nouveau_drm(dev); > struct nvkm_i2c_aux *aux; > u8 dpcd[8]; > + u8 port_cap[DP_MAX_DOWNSTREAM_PORTS] = {0}; IIRC clang will complain about {0}. How about we make this a {}. Regardless of the above nitpick, the series is: Reviewed-by: Emil Velikov <emil.velikov at collabora.com> Thanks for the follow-up :-) Emil
2020 Aug 26
0
[PATCH v5 14/20] drm/nouveau/kms/nv50-: Use downstream DP clock limits for mode validation
.../nouveau/nouveau_encoder.h index eef4643f5f982..c1924a4529a7b 100644 --- a/drivers/gpu/drm/nouveau/nouveau_encoder.h +++ b/drivers/gpu/drm/nouveau/nouveau_encoder.h @@ -72,6 +72,7 @@ struct nouveau_encoder { struct mutex hpd_irq_lock; u8 dpcd[DP_RECEIVER_CAP_SIZE]; + u8 downstream_ports[DP_MAX_DOWNSTREAM_PORTS]; struct drm_dp_desc desc; } dp; }; -- 2.26.2
2020 Aug 11
29
[RFC 00/20] drm/dp, i915, nouveau: Cleanup nouveau HPD and add DP features from i915
To start off: this patch series is less work to review then it looks - most (but not all) of the nouveau related work has already been reviewed elsewhere. Most of the reason I'm asking for an RFC here is because this code pulls a lot of code out of i915 and into shared DP helpers. Anyway-nouveau's HPD related code has been collecting dust for a while. Other then the occasional runtime PM