All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
@ 2018-05-16 16:33 matthew.s.atwood
  2018-05-16 17:17 ` ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
                   ` (4 more replies)
  0 siblings, 5 replies; 12+ messages in thread
From: matthew.s.atwood @ 2018-05-16 16:33 UTC (permalink / raw)
  To: intel-gfx, rodrigo.vivi, bleung, paulo.r.zanoni

From: Matt Atwood <matthew.s.atwood@intel.com>

According to DP spec (2.9.3.1 of DP 1.4) if
EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT is set the addresses in DPCD
02200h through 0220Fh shall contain the DPRX's true capability. These
values will match 00000h through 0000Fh, except for DPCD_REV,
MAX_LINK_RATE, DOWN_STREAM_PORT_PRESENT.

Read from DPCD once for all 3 values as this is an expensive operation.
Spec mentions that all of address space 02200h through 0220Fh should
contain the right information however currently only 3 values can
differ.

There is no address space in the intel_dp->dpcd struct for addresses
02200h through 0220Fh, and since so much of the data is a identical,
simply overwrite the values stored in 00000h through 0000Fh with the
values that can be overwritten from addresses 02200h through 0220Fh

Signed-off-by: Matt Atwood <matthew.s.atwood@intel.com>
---
 drivers/gpu/drm/i915/intel_dp.c | 14 ++++++++++++++
 include/drm/drm_dp_helper.h     |  5 +++--
 2 files changed, 17 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index dde92e4af5d3..899ebc5cece6 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -3738,6 +3738,20 @@ intel_dp_read_dpcd(struct intel_dp *intel_dp)
 			     sizeof(intel_dp->dpcd)) < 0)
 		return false; /* aux transfer failed */
 
+	if (intel_dp->dpcd[DP_TRAINING_AUX_RD_INTERVAL] &
+	    DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT &&
+	    intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14) {
+		uint8_t dpcd_ext[16];
+
+		if (drm_dp_dpcd_read(&intel_dp->aux, DP_DP13_DPCD_REV,
+		    &dpcd_ext, sizeof(dpcd_ext)) < 0)
+			return false; /* aux transfer failed */
+
+		intel_dp->dpcd[DP_DPCD_REV] = dpcd_ext[DP_DPCD_REV];
+		intel_dp->dpcd[DP_MAX_LINK_RATE] = dpcd_ext[DP_MAX_LINK_RATE];
+		intel_dp->dpcd[DP_DOWNSTREAMPORT_PRESENT] =
+			dpcd_ext[DP_DOWNSTREAMPORT_PRESENT];
+	}
 	DRM_DEBUG_KMS("DPCD: %*ph\n", (int) sizeof(intel_dp->dpcd), intel_dp->dpcd);
 
 	return intel_dp->dpcd[DP_DPCD_REV] != 0;
diff --git a/include/drm/drm_dp_helper.h b/include/drm/drm_dp_helper.h
index c01564991a9f..757bd5913f3d 100644
--- a/include/drm/drm_dp_helper.h
+++ b/include/drm/drm_dp_helper.h
@@ -123,8 +123,9 @@
 # define DP_FRAMING_CHANGE_CAP		    (1 << 1)
 # define DP_DPCD_DISPLAY_CONTROL_CAPABLE     (1 << 3) /* edp v1.2 or higher */
 
-#define DP_TRAINING_AUX_RD_INTERVAL         0x00e   /* XXX 1.2? */
-# define DP_TRAINING_AUX_RD_MASK            0x7F    /* XXX 1.2? */
+#define DP_TRAINING_AUX_RD_INTERVAL             0x00e   /* XXX 1.2? */
+# define DP_TRAINING_AUX_RD_MASK                0x7F    /* XXX 1.2? */
+# define DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT (1 << 7)/* XXX 1.2? */
 
 #define DP_ADAPTER_CAP			    0x00f   /* 1.2 */
 # define DP_FORCE_LOAD_SENSE_CAP	    (1 << 0)
-- 
2.17.0

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

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* ✗ Fi.CI.CHECKPATCH: warning for drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
  2018-05-16 16:33 [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT matthew.s.atwood
@ 2018-05-16 17:17 ` Patchwork
  2018-05-16 17:33 ` ✓ Fi.CI.BAT: success " Patchwork
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2018-05-16 17:17 UTC (permalink / raw)
  To: matthew.s.atwood; +Cc: intel-gfx

== Series Details ==

Series: drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
URL   : https://patchwork.freedesktop.org/series/43275/
State : warning

== Summary ==

$ dim checkpatch origin/drm-tip
7ccc09d99eca drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
-:38: CHECK:PARENTHESIS_ALIGNMENT: Alignment should match open parenthesis
#38: FILE: drivers/gpu/drm/i915/intel_dp.c:3747:
+		if (drm_dp_dpcd_read(&intel_dp->aux, DP_DP13_DPCD_REV,
+		    &dpcd_ext, sizeof(dpcd_ext)) < 0)

total: 0 errors, 0 warnings, 1 checks, 31 lines checked

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

^ permalink raw reply	[flat|nested] 12+ messages in thread

* ✓ Fi.CI.BAT: success for drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
  2018-05-16 16:33 [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT matthew.s.atwood
  2018-05-16 17:17 ` ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
@ 2018-05-16 17:33 ` Patchwork
  2018-05-16 22:31 ` [PATCH] " Dhinakaran Pandiyan
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2018-05-16 17:33 UTC (permalink / raw)
  To: matthew.s.atwood; +Cc: intel-gfx

== Series Details ==

Series: drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
URL   : https://patchwork.freedesktop.org/series/43275/
State : success

== Summary ==

= CI Bug Log - changes from CI_DRM_4193 -> Patchwork_9020 =

== Summary - WARNING ==

  Minor unknown changes coming with Patchwork_9020 need to be verified
  manually.
  
  If you think the reported changes have nothing to do with the changes
  introduced in Patchwork_9020, please notify your bug team to allow them
  to document this new failure mode, which will reduce false positives in CI.

  External URL: https://patchwork.freedesktop.org/api/1.0/series/43275/revisions/1/mbox/

== Possible new issues ==

  Here are the unknown changes that may have been introduced in Patchwork_9020:

  === IGT changes ===

    ==== Warnings ====

    igt@gem_exec_gttfill@basic:
      fi-pnv-d510:        SKIP -> PASS

    igt@kms_force_connector_basic@prune-stale-modes:
      fi-snb-2600:        PASS -> SKIP

    
== Known issues ==

  Here are the changes found in Patchwork_9020 that come from known issues:

  === IGT changes ===

    ==== Possible fixes ====

    igt@kms_pipe_crc_basic@nonblocking-crc-pipe-a-frame-sequence:
      fi-cfl-s3:          FAIL (fdo#103481) -> PASS +1

    igt@kms_pipe_crc_basic@suspend-read-crc-pipe-a:
      fi-cnl-psr:         DMESG-WARN (fdo#104951) -> PASS

    
  fdo#103481 https://bugs.freedesktop.org/show_bug.cgi?id=103481
  fdo#104951 https://bugs.freedesktop.org/show_bug.cgi?id=104951


== Participating hosts (41 -> 36) ==

  Missing    (5): fi-ctg-p8600 fi-ilk-m540 fi-byt-squawks fi-bsw-cyan fi-skl-6700hq 


== Build changes ==

    * Linux: CI_DRM_4193 -> Patchwork_9020

  CI_DRM_4193: 9322e3903ce6c89bde0c24877fe730b808427caf @ git://anongit.freedesktop.org/gfx-ci/linux
  IGT_4485: eccae1360d6d01e73c6af2bd97122cef708207ef @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
  Patchwork_9020: 7ccc09d99ecac09bba1c3f9247a5511a2872d96f @ git://anongit.freedesktop.org/gfx-ci/linux
  piglit_4485: 62ef6b0db8967e7021fd3e0b57d03ff164b984fe @ git://anongit.freedesktop.org/piglit


== Linux commits ==

7ccc09d99eca drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_9020/issues.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
  2018-05-16 22:31 ` [PATCH] " Dhinakaran Pandiyan
@ 2018-05-16 22:23   ` Manasi Navare
  2018-05-17  9:50   ` Jani Nikula
  1 sibling, 0 replies; 12+ messages in thread
From: Manasi Navare @ 2018-05-16 22:23 UTC (permalink / raw)
  To: Dhinakaran Pandiyan; +Cc: intel-gfx, paulo.r.zanoni, rodrigo.vivi

On Wed, May 16, 2018 at 03:31:52PM -0700, Dhinakaran Pandiyan wrote:
> On Wed, 2018-05-16 at 09:33 -0700, matthew.s.atwood@intel.com wrote:
> > From: Matt Atwood <matthew.s.atwood@intel.com>
> > 
> > According to DP spec (2.9.3.1 of DP 1.4) if
> > EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT is set the addresses in
> > DPCD
> > 02200h through 0220Fh shall contain the DPRX's true capability. These
> > values will match 00000h through 0000Fh, except for DPCD_REV,
> > MAX_LINK_RATE, DOWN_STREAM_PORT_PRESENT.
> > 
> > Read from DPCD once for all 3 values as this is an expensive
> > operation.
> > Spec mentions that all of address space 02200h through 0220Fh should
> > contain the right information however currently only 3 values can
> > differ.
> > 
> > There is no address space in the intel_dp->dpcd struct for addresses
> > 02200h through 0220Fh, and since so much of the data is a identical,
> > simply overwrite the values stored in 00000h through 0000Fh with the
> > values that can be overwritten from addresses 02200h through 0220Fh
> 
> Why overwrite all values if this is an expensive operation? From what I
> can see, you'll need to read only 0000h - 00005h
> 
> > 
> > Signed-off-by: Matt Atwood <matthew.s.atwood@intel.com>
> > ---
> >  drivers/gpu/drm/i915/intel_dp.c | 14 ++++++++++++++
> >  include/drm/drm_dp_helper.h     |  5 +++--
> >  2 files changed, 17 insertions(+), 2 deletions(-)
> > 
> > diff --git a/drivers/gpu/drm/i915/intel_dp.c
> > b/drivers/gpu/drm/i915/intel_dp.c
> > index dde92e4af5d3..899ebc5cece6 100644
> > --- a/drivers/gpu/drm/i915/intel_dp.c
> > +++ b/drivers/gpu/drm/i915/intel_dp.c
> > @@ -3738,6 +3738,20 @@ intel_dp_read_dpcd(struct intel_dp *intel_dp)
> >  			     sizeof(intel_dp->dpcd)) < 0)
> >  		return false; /* aux transfer failed */
> >  
> > +	if (intel_dp->dpcd[DP_TRAINING_AUX_RD_INTERVAL] &
> > +	    DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT &&
> > +	    intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14) {
> 
> The same section in the spec also says - "The Extended Receiver
> Capability registers at DPCD Addresses 02200h through 0220Fh shall
> contain the DPRX’s true capability, while the original Base Receiver
> Capability registers at DPCD Addresses 00000h through 0000Fh might
> indicate DPCD r1.1, a MAX_LINK_RATE of 2.7Gbps/lane, and no DFP to
> avoid interoperability issues ..."
> 
> Which means, intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14 is probably
> not going to be true for panels you want to read the extended
> capabilities for.

Yes thats a good point. So just check on the EXTENDED_EXTENDED_RECEIVER_CAP_FIELD_PRESENT
should suffice.
 
> 
> > +		uint8_t dpcd_ext[16];
> > +
> > +		if (drm_dp_dpcd_read(&intel_dp->aux,
> > DP_DP13_DPCD_REV,
> > +		    &dpcd_ext, sizeof(dpcd_ext)) < 0)
> > +			return false; /* aux transfer failed */
> > +
> > +		intel_dp->dpcd[DP_DPCD_REV] = dpcd_ext[DP_DPCD_REV];
> > +		intel_dp->dpcd[DP_MAX_LINK_RATE] =
> > dpcd_ext[DP_MAX_LINK_RATE];
> > +		intel_dp->dpcd[DP_DOWNSTREAMPORT_PRESENT] =
> > +			dpcd_ext[DP_DOWNSTREAMPORT_PRESENT];
> > +	}
> >  	DRM_DEBUG_KMS("DPCD: %*ph\n", (int) sizeof(intel_dp->dpcd),
> > intel_dp->dpcd);
> >  
> >  	return intel_dp->dpcd[DP_DPCD_REV] != 0;
> > diff --git a/include/drm/drm_dp_helper.h
> > b/include/drm/drm_dp_helper.h
> > index c01564991a9f..757bd5913f3d 100644
> > --- a/include/drm/drm_dp_helper.h
> > +++ b/include/drm/drm_dp_helper.h
> 
> This should be a separate patch as it's outside i915.

And also send this patch to dri-devel M-L

Manasi

> 
> > @@ -123,8 +123,9 @@
> >  # define DP_FRAMING_CHANGE_CAP		    (1 << 1)
> >  # define DP_DPCD_DISPLAY_CONTROL_CAPABLE     (1 << 3) /* edp v1.2 or
> > higher */
> >  
> > -#define DP_TRAINING_AUX_RD_INTERVAL         0x00e   /* XXX 1.2? */
> > -# define DP_TRAINING_AUX_RD_MASK            0x7F    /* XXX 1.2? */
> > +#define DP_TRAINING_AUX_RD_INTERVAL             0x00e   /* XXX 1.2?
> > */
> > +# define DP_TRAINING_AUX_RD_MASK                0x7F    /* XXX 1.2?
> > */
> > +# define DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT (1 << 7)/* XXX 1.2?
> > */
> >  
> >  #define DP_ADAPTER_CAP			    0x00f   /* 1.2 */
> >  # define DP_FORCE_LOAD_SENSE_CAP	    (1 << 0)
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
  2018-05-16 16:33 [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT matthew.s.atwood
  2018-05-16 17:17 ` ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
  2018-05-16 17:33 ` ✓ Fi.CI.BAT: success " Patchwork
@ 2018-05-16 22:31 ` Dhinakaran Pandiyan
  2018-05-16 22:23   ` Manasi Navare
  2018-05-17  9:50   ` Jani Nikula
  2018-05-17  1:27 ` ✓ Fi.CI.IGT: success for " Patchwork
  2018-06-26  0:39 ` [PATCH] " Manasi Navare
  4 siblings, 2 replies; 12+ messages in thread
From: Dhinakaran Pandiyan @ 2018-05-16 22:31 UTC (permalink / raw)
  To: matthew.s.atwood, intel-gfx, rodrigo.vivi, bleung, paulo.r.zanoni

On Wed, 2018-05-16 at 09:33 -0700, matthew.s.atwood@intel.com wrote:
> From: Matt Atwood <matthew.s.atwood@intel.com>
> 
> According to DP spec (2.9.3.1 of DP 1.4) if
> EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT is set the addresses in
> DPCD
> 02200h through 0220Fh shall contain the DPRX's true capability. These
> values will match 00000h through 0000Fh, except for DPCD_REV,
> MAX_LINK_RATE, DOWN_STREAM_PORT_PRESENT.
> 
> Read from DPCD once for all 3 values as this is an expensive
> operation.
> Spec mentions that all of address space 02200h through 0220Fh should
> contain the right information however currently only 3 values can
> differ.
> 
> There is no address space in the intel_dp->dpcd struct for addresses
> 02200h through 0220Fh, and since so much of the data is a identical,
> simply overwrite the values stored in 00000h through 0000Fh with the
> values that can be overwritten from addresses 02200h through 0220Fh

Why overwrite all values if this is an expensive operation? From what I
can see, you'll need to read only 0000h - 00005h

> 
> Signed-off-by: Matt Atwood <matthew.s.atwood@intel.com>
> ---
>  drivers/gpu/drm/i915/intel_dp.c | 14 ++++++++++++++
>  include/drm/drm_dp_helper.h     |  5 +++--
>  2 files changed, 17 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_dp.c
> b/drivers/gpu/drm/i915/intel_dp.c
> index dde92e4af5d3..899ebc5cece6 100644
> --- a/drivers/gpu/drm/i915/intel_dp.c
> +++ b/drivers/gpu/drm/i915/intel_dp.c
> @@ -3738,6 +3738,20 @@ intel_dp_read_dpcd(struct intel_dp *intel_dp)
>  			     sizeof(intel_dp->dpcd)) < 0)
>  		return false; /* aux transfer failed */
>  
> +	if (intel_dp->dpcd[DP_TRAINING_AUX_RD_INTERVAL] &
> +	    DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT &&
> +	    intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14) {

The same section in the spec also says - "The Extended Receiver
Capability registers at DPCD Addresses 02200h through 0220Fh shall
contain the DPRX’s true capability, while the original Base Receiver
Capability registers at DPCD Addresses 00000h through 0000Fh might
indicate DPCD r1.1, a MAX_LINK_RATE of 2.7Gbps/lane, and no DFP to
avoid interoperability issues ..."

Which means, intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14 is probably
not going to be true for panels you want to read the extended
capabilities for. 

> +		uint8_t dpcd_ext[16];
> +
> +		if (drm_dp_dpcd_read(&intel_dp->aux,
> DP_DP13_DPCD_REV,
> +		    &dpcd_ext, sizeof(dpcd_ext)) < 0)
> +			return false; /* aux transfer failed */
> +
> +		intel_dp->dpcd[DP_DPCD_REV] = dpcd_ext[DP_DPCD_REV];
> +		intel_dp->dpcd[DP_MAX_LINK_RATE] =
> dpcd_ext[DP_MAX_LINK_RATE];
> +		intel_dp->dpcd[DP_DOWNSTREAMPORT_PRESENT] =
> +			dpcd_ext[DP_DOWNSTREAMPORT_PRESENT];
> +	}
>  	DRM_DEBUG_KMS("DPCD: %*ph\n", (int) sizeof(intel_dp->dpcd),
> intel_dp->dpcd);
>  
>  	return intel_dp->dpcd[DP_DPCD_REV] != 0;
> diff --git a/include/drm/drm_dp_helper.h
> b/include/drm/drm_dp_helper.h
> index c01564991a9f..757bd5913f3d 100644
> --- a/include/drm/drm_dp_helper.h
> +++ b/include/drm/drm_dp_helper.h

This should be a separate patch as it's outside i915.

> @@ -123,8 +123,9 @@
>  # define DP_FRAMING_CHANGE_CAP		    (1 << 1)
>  # define DP_DPCD_DISPLAY_CONTROL_CAPABLE     (1 << 3) /* edp v1.2 or
> higher */
>  
> -#define DP_TRAINING_AUX_RD_INTERVAL         0x00e   /* XXX 1.2? */
> -# define DP_TRAINING_AUX_RD_MASK            0x7F    /* XXX 1.2? */
> +#define DP_TRAINING_AUX_RD_INTERVAL             0x00e   /* XXX 1.2?
> */
> +# define DP_TRAINING_AUX_RD_MASK                0x7F    /* XXX 1.2?
> */
> +# define DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT (1 << 7)/* XXX 1.2?
> */
>  
>  #define DP_ADAPTER_CAP			    0x00f   /* 1.2 */
>  # define DP_FORCE_LOAD_SENSE_CAP	    (1 << 0)
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 12+ messages in thread

* ✓ Fi.CI.IGT: success for drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
  2018-05-16 16:33 [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT matthew.s.atwood
                   ` (2 preceding siblings ...)
  2018-05-16 22:31 ` [PATCH] " Dhinakaran Pandiyan
@ 2018-05-17  1:27 ` Patchwork
  2018-06-26  0:39 ` [PATCH] " Manasi Navare
  4 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2018-05-17  1:27 UTC (permalink / raw)
  To: matthew.s.atwood; +Cc: intel-gfx

== Series Details ==

Series: drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
URL   : https://patchwork.freedesktop.org/series/43275/
State : success

== Summary ==

= CI Bug Log - changes from CI_DRM_4193_full -> Patchwork_9020_full =

== Summary - WARNING ==

  Minor unknown changes coming with Patchwork_9020_full need to be verified
  manually.
  
  If you think the reported changes have nothing to do with the changes
  introduced in Patchwork_9020_full, please notify your bug team to allow them
  to document this new failure mode, which will reduce false positives in CI.

  External URL: https://patchwork.freedesktop.org/api/1.0/series/43275/revisions/1/mbox/

== Possible new issues ==

  Here are the unknown changes that may have been introduced in Patchwork_9020_full:

  === IGT changes ===

    ==== Warnings ====

    igt@gem_exec_schedule@deep-render:
      shard-kbl:          SKIP -> PASS

    igt@kms_cursor_legacy@cursora-vs-flipb-varying-size:
      shard-hsw:          PASS -> SKIP

    
== Known issues ==

  Here are the changes found in Patchwork_9020_full that come from known issues:

  === IGT changes ===

    ==== Issues hit ====

    igt@gem_eio@execbuf:
      shard-glk:          PASS -> DMESG-WARN (fdo#106523)

    igt@gem_eio@in-flight-contexts-immediate:
      shard-hsw:          PASS -> DMESG-WARN (fdo#106523) +1

    igt@gem_eio@in-flight-internal-10ms:
      shard-snb:          PASS -> DMESG-WARN (fdo#106523)

    igt@gem_eio@suspend:
      shard-apl:          PASS -> DMESG-WARN (fdo#106523)

    igt@kms_flip@2x-wf_vblank-ts-check-interruptible:
      shard-hsw:          PASS -> FAIL (fdo#100368)

    igt@kms_flip@dpms-vs-vblank-race-interruptible:
      shard-hsw:          PASS -> FAIL (fdo#103060)

    igt@kms_flip@modeset-vs-vblank-race:
      shard-glk:          PASS -> FAIL (fdo#103060) +1

    igt@kms_flip@plain-flip-ts-check:
      shard-glk:          PASS -> FAIL (fdo#100368) +1

    igt@kms_flip_tiling@flip-x-tiled:
      shard-glk:          PASS -> FAIL (fdo#104724, fdo#103822)

    igt@kms_frontbuffer_tracking@fbc-2p-primscrn-shrfb-msflip-blt:
      shard-glk:          PASS -> FAIL (fdo#104724, fdo#103167) +1

    
    ==== Possible fixes ====

    igt@gem_eio@execbuf:
      shard-hsw:          DMESG-WARN (fdo#106523) -> PASS

    igt@gem_eio@in-flight-immediate:
      shard-snb:          DMESG-WARN (fdo#106523) -> PASS +1

    igt@gem_eio@wait-wedge-1us:
      shard-apl:          DMESG-WARN (fdo#106523) -> PASS

    igt@kms_flip@dpms-vs-vblank-race:
      shard-hsw:          FAIL (fdo#103060) -> PASS

    igt@kms_flip@flip-vs-expired-vblank:
      shard-glk:          FAIL (fdo#105363) -> PASS

    igt@kms_flip_tiling@flip-to-x-tiled:
      shard-glk:          FAIL (fdo#104724, fdo#103822) -> PASS +1

    igt@kms_setmode@basic:
      shard-kbl:          FAIL (fdo#99912) -> PASS

    
  fdo#100368 https://bugs.freedesktop.org/show_bug.cgi?id=100368
  fdo#103060 https://bugs.freedesktop.org/show_bug.cgi?id=103060
  fdo#103167 https://bugs.freedesktop.org/show_bug.cgi?id=103167
  fdo#103822 https://bugs.freedesktop.org/show_bug.cgi?id=103822
  fdo#104724 https://bugs.freedesktop.org/show_bug.cgi?id=104724
  fdo#105363 https://bugs.freedesktop.org/show_bug.cgi?id=105363
  fdo#106523 https://bugs.freedesktop.org/show_bug.cgi?id=106523
  fdo#99912 https://bugs.freedesktop.org/show_bug.cgi?id=99912


== Participating hosts (5 -> 5) ==

  No changes in participating hosts


== Build changes ==

    * Linux: CI_DRM_4193 -> Patchwork_9020

  CI_DRM_4193: 9322e3903ce6c89bde0c24877fe730b808427caf @ git://anongit.freedesktop.org/gfx-ci/linux
  IGT_4485: eccae1360d6d01e73c6af2bd97122cef708207ef @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
  Patchwork_9020: 7ccc09d99ecac09bba1c3f9247a5511a2872d96f @ git://anongit.freedesktop.org/gfx-ci/linux
  piglit_4485: 62ef6b0db8967e7021fd3e0b57d03ff164b984fe @ git://anongit.freedesktop.org/piglit

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_9020/shards.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
  2018-05-16 22:31 ` [PATCH] " Dhinakaran Pandiyan
  2018-05-16 22:23   ` Manasi Navare
@ 2018-05-17  9:50   ` Jani Nikula
  2018-05-17 15:29     ` Atwood, Matthew S
  1 sibling, 1 reply; 12+ messages in thread
From: Jani Nikula @ 2018-05-17  9:50 UTC (permalink / raw)
  To: dhinakaran.pandiyan, matthew.s.atwood, intel-gfx, rodrigo.vivi,
	bleung, paulo.r.zanoni

On Wed, 16 May 2018, Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com> wrote:
> On Wed, 2018-05-16 at 09:33 -0700, matthew.s.atwood@intel.com wrote:
>> From: Matt Atwood <matthew.s.atwood@intel.com>
>> 
>> According to DP spec (2.9.3.1 of DP 1.4) if
>> EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT is set the addresses in
>> DPCD
>> 02200h through 0220Fh shall contain the DPRX's true capability. These
>> values will match 00000h through 0000Fh, except for DPCD_REV,
>> MAX_LINK_RATE, DOWN_STREAM_PORT_PRESENT.
>> 
>> Read from DPCD once for all 3 values as this is an expensive
>> operation.
>> Spec mentions that all of address space 02200h through 0220Fh should
>> contain the right information however currently only 3 values can
>> differ.
>> 
>> There is no address space in the intel_dp->dpcd struct for addresses
>> 02200h through 0220Fh, and since so much of the data is a identical,
>> simply overwrite the values stored in 00000h through 0000Fh with the
>> values that can be overwritten from addresses 02200h through 0220Fh

Without reading the spec, this commit message makes one think there's no
point in any of this. Please mention this is for backward compatibility
with older source devices that trip over because of newer DPCD.

> Why overwrite all values if this is an expensive operation? From what I
> can see, you'll need to read only 0000h - 00005h
>
>> 
>> Signed-off-by: Matt Atwood <matthew.s.atwood@intel.com>
>> ---
>>  drivers/gpu/drm/i915/intel_dp.c | 14 ++++++++++++++
>>  include/drm/drm_dp_helper.h     |  5 +++--
>>  2 files changed, 17 insertions(+), 2 deletions(-)
>> 
>> diff --git a/drivers/gpu/drm/i915/intel_dp.c
>> b/drivers/gpu/drm/i915/intel_dp.c
>> index dde92e4af5d3..899ebc5cece6 100644
>> --- a/drivers/gpu/drm/i915/intel_dp.c
>> +++ b/drivers/gpu/drm/i915/intel_dp.c
>> @@ -3738,6 +3738,20 @@ intel_dp_read_dpcd(struct intel_dp *intel_dp)
>>  			     sizeof(intel_dp->dpcd)) < 0)
>>  		return false; /* aux transfer failed */
>>  
>> +	if (intel_dp->dpcd[DP_TRAINING_AUX_RD_INTERVAL] &
>> +	    DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT &&
>> +	    intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14) {
>
> The same section in the spec also says - "The Extended Receiver
> Capability registers at DPCD Addresses 02200h through 0220Fh shall
> contain the DPRX’s true capability, while the original Base Receiver
> Capability registers at DPCD Addresses 00000h through 0000Fh might
> indicate DPCD r1.1, a MAX_LINK_RATE of 2.7Gbps/lane, and no DFP to
> avoid interoperability issues ..."
>
> Which means, intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14 is probably
> not going to be true for panels you want to read the extended
> capabilities for. 

Agreed. Only check DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT.

>
>> +		uint8_t dpcd_ext[16];

u8.

>> +
>> +		if (drm_dp_dpcd_read(&intel_dp->aux,
>> DP_DP13_DPCD_REV,
>> +		    &dpcd_ext, sizeof(dpcd_ext)) < 0)
>> +			return false; /* aux transfer failed */

Please don't return false here. Just waltz on.

Like DK said, please read the minimal amount. Please memcmp those six
bytes against the already read DPCD, and debug log the *old* bytes if
there's a diff (new bytes debug logged below), and memcpy the new parts
in place.

>> +
>> +		intel_dp->dpcd[DP_DPCD_REV] = dpcd_ext[DP_DPCD_REV];
>> +		intel_dp->dpcd[DP_MAX_LINK_RATE] =
>> dpcd_ext[DP_MAX_LINK_RATE];
>> +		intel_dp->dpcd[DP_DOWNSTREAMPORT_PRESENT] =
>> +			dpcd_ext[DP_DOWNSTREAMPORT_PRESENT];
>> +	}
>>  	DRM_DEBUG_KMS("DPCD: %*ph\n", (int) sizeof(intel_dp->dpcd),
>> intel_dp->dpcd);
>>  
>>  	return intel_dp->dpcd[DP_DPCD_REV] != 0;
>> diff --git a/include/drm/drm_dp_helper.h
>> b/include/drm/drm_dp_helper.h
>> index c01564991a9f..757bd5913f3d 100644
>> --- a/include/drm/drm_dp_helper.h
>> +++ b/include/drm/drm_dp_helper.h
>
> This should be a separate patch as it's outside i915.

Yes.

>
>> @@ -123,8 +123,9 @@
>>  # define DP_FRAMING_CHANGE_CAP		    (1 << 1)
>>  # define DP_DPCD_DISPLAY_CONTROL_CAPABLE     (1 << 3) /* edp v1.2 or
>> higher */
>>  
>> -#define DP_TRAINING_AUX_RD_INTERVAL         0x00e   /* XXX 1.2? */
>> -# define DP_TRAINING_AUX_RD_MASK            0x7F    /* XXX 1.2? */
>> +#define DP_TRAINING_AUX_RD_INTERVAL             0x00e   /* XXX 1.2?
>> */
>> +# define DP_TRAINING_AUX_RD_MASK                0x7F    /* XXX 1.2?
>> */
>> +# define DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT (1 << 7)/* XXX 1.2?

Surely this is not XXX 1.2? ;)

BR,
Jani.

>> */
>>  
>>  #define DP_ADAPTER_CAP			    0x00f   /* 1.2 */
>>  # define DP_FORCE_LOAD_SENSE_CAP	    (1 << 0)
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
  2018-05-17  9:50   ` Jani Nikula
@ 2018-05-17 15:29     ` Atwood, Matthew S
  2018-05-17 17:53       ` Jani Nikula
  0 siblings, 1 reply; 12+ messages in thread
From: Atwood, Matthew S @ 2018-05-17 15:29 UTC (permalink / raw)
  To: intel-gfx, Vivi, Rodrigo, jani.nikula, Pandiyan, Dhinakaran,
	Zanoni, Paulo R, bleung

On Thu, 2018-05-17 at 12:50 +0300, Jani Nikula wrote:
> On Wed, 16 May 2018, Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.c
> om> wrote:
> > On Wed, 2018-05-16 at 09:33 -0700, matthew.s.atwood@intel.com
> > wrote:
> > > From: Matt Atwood <matthew.s.atwood@intel.com>
> > > 
> > > According to DP spec (2.9.3.1 of DP 1.4) if
> > > EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT is set the addresses
> > > in
> > > DPCD
> > > 02200h through 0220Fh shall contain the DPRX's true capability.
> > > These
> > > values will match 00000h through 0000Fh, except for DPCD_REV,
> > > MAX_LINK_RATE, DOWN_STREAM_PORT_PRESENT.
> > > 
> > > Read from DPCD once for all 3 values as this is an expensive
> > > operation.
> > > Spec mentions that all of address space 02200h through 0220Fh
> > > should
> > > contain the right information however currently only 3 values can
> > > differ.
> > > 
> > > There is no address space in the intel_dp->dpcd struct for
> > > addresses
> > > 02200h through 0220Fh, and since so much of the data is a
> > > identical,
> > > simply overwrite the values stored in 00000h through 0000Fh with
> > > the
> > > values that can be overwritten from addresses 02200h through
> > > 0220Fh
> 
> Without reading the spec, this commit message makes one think there's
> no
> point in any of this. Please mention this is for backward
> compatibility
> with older source devices that trip over because of newer DPCD.
sure thing
> 
> > Why overwrite all values if this is an expensive operation? From
> > what I
> > can see, you'll need to read only 0000h - 00005h
was mostly future proofing, we can get away with only reading 6 values.
the expense is to read 1, any number after that doesnt cost alot. That
being said sure thing.
> > 
> > > 
> > > Signed-off-by: Matt Atwood <matthew.s.atwood@intel.com>
> > > ---
> > >  drivers/gpu/drm/i915/intel_dp.c | 14 ++++++++++++++
> > >  include/drm/drm_dp_helper.h     |  5 +++--
> > >  2 files changed, 17 insertions(+), 2 deletions(-)
> > > 
> > > diff --git a/drivers/gpu/drm/i915/intel_dp.c
> > > b/drivers/gpu/drm/i915/intel_dp.c
> > > index dde92e4af5d3..899ebc5cece6 100644
> > > --- a/drivers/gpu/drm/i915/intel_dp.c
> > > +++ b/drivers/gpu/drm/i915/intel_dp.c
> > > @@ -3738,6 +3738,20 @@ intel_dp_read_dpcd(struct intel_dp
> > > *intel_dp)
> > >  			     sizeof(intel_dp->dpcd)) < 0)
> > >  		return false; /* aux transfer failed */
> > >  
> > > +	if (intel_dp->dpcd[DP_TRAINING_AUX_RD_INTERVAL] &
> > > +	    DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT &&
> > > +	    intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14) {
> > 
> > The same section in the spec also says - "The Extended Receiver
> > Capability registers at DPCD Addresses 02200h through 0220Fh shall
> > contain the DPRX’s true capability, while the original Base
> > Receiver
> > Capability registers at DPCD Addresses 00000h through 0000Fh might
> > indicate DPCD r1.1, a MAX_LINK_RATE of 2.7Gbps/lane, and no DFP to
> > avoid interoperability issues ..."
> > 
> > Which means, intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14 is
> > probably
> > not going to be true for panels you want to read the extended
> > capabilities for. 
> 
> Agreed. Only check DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT.
sure
> 
> > 
> > > +		uint8_t dpcd_ext[16];
> 
> u8.
> 
> > > +
> > > +		if (drm_dp_dpcd_read(&intel_dp->aux,
> > > DP_DP13_DPCD_REV,
> > > +		    &dpcd_ext, sizeof(dpcd_ext)) < 0)
> > > +			return false; /* aux transfer failed */
> 
> Please don't return false here. Just waltz on.
sure
> 
> Like DK said, please read the minimal amount. Please memcmp those six
> bytes against the already read DPCD, and debug log the *old* bytes if
> there's a diff (new bytes debug logged below), and memcpy the new
> parts
> in place.
I really like this idea. thanks!
> 
> > > +
> > > +		intel_dp->dpcd[DP_DPCD_REV] =
> > > dpcd_ext[DP_DPCD_REV];
> > > +		intel_dp->dpcd[DP_MAX_LINK_RATE] =
> > > dpcd_ext[DP_MAX_LINK_RATE];
> > > +		intel_dp->dpcd[DP_DOWNSTREAMPORT_PRESENT] =
> > > +			dpcd_ext[DP_DOWNSTREAMPORT_PRESENT];
> > > +	}
> > >  	DRM_DEBUG_KMS("DPCD: %*ph\n", (int) sizeof(intel_dp-
> > > >dpcd),
> > > intel_dp->dpcd);
> > >  
> > >  	return intel_dp->dpcd[DP_DPCD_REV] != 0;
> > > diff --git a/include/drm/drm_dp_helper.h
> > > b/include/drm/drm_dp_helper.h
> > > index c01564991a9f..757bd5913f3d 100644
> > > --- a/include/drm/drm_dp_helper.h
> > > +++ b/include/drm/drm_dp_helper.h
> > 
> > This should be a separate patch as it's outside i915.
no problem
> 
> Yes.
> 
> > 
> > > @@ -123,8 +123,9 @@
> > >  # define DP_FRAMING_CHANGE_CAP		    (1 << 1)
> > >  # define DP_DPCD_DISPLAY_CONTROL_CAPABLE     (1 << 3) /* edp
> > > v1.2 or
> > > higher */
> > >  
> > > -#define DP_TRAINING_AUX_RD_INTERVAL         0x00e   /* XXX 1.2?
> > > */
> > > -# define DP_TRAINING_AUX_RD_MASK            0x7F    /* XXX 1.2?
> > > */
> > > +#define DP_TRAINING_AUX_RD_INTERVAL             0x00e   /* XXX
> > > 1.2?
> > > */
> > > +# define DP_TRAINING_AUX_RD_MASK                0x7F    /* XXX
> > > 1.2?
> > > */
> > > +# define DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT (1 << 7)/* XXX
> > > 1.2?
> 
> Surely this is not XXX 1.2? ;)
I found it in a dp1.2 spec that Rodrigo had, I had originally found it
as a change with dp1.3. Earlier versions of the patch that added
DP_TRAINING_AUX_RD_MASK has had dp1.3 until he showed me that. If you'd
like Ill change it.
> 
> BR,
> Jani.
> 
> > > */
> > >  
> > >  #define DP_ADAPTER_CAP			    0x00f   /* 1.2
> > > */
> > >  # define DP_FORCE_LOAD_SENSE_CAP	    (1 << 0)
> > 
> > _______________________________________________
> > Intel-gfx mailing list
> > Intel-gfx@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/intel-gfx
> 
> 
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
  2018-05-17 15:29     ` Atwood, Matthew S
@ 2018-05-17 17:53       ` Jani Nikula
  0 siblings, 0 replies; 12+ messages in thread
From: Jani Nikula @ 2018-05-17 17:53 UTC (permalink / raw)
  To: Atwood, Matthew S, intel-gfx, Vivi, Rodrigo, Pandiyan,
	Dhinakaran, Zanoni, Paulo R, bleung

On Thu, 17 May 2018, "Atwood, Matthew S" <matthew.s.atwood@intel.com> wrote:
> On Thu, 2018-05-17 at 12:50 +0300, Jani Nikula wrote:
>> On Wed, 16 May 2018, Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.c
>> om> wrote:
>> > Why overwrite all values if this is an expensive operation? From
>> > what I
>> > can see, you'll need to read only 0000h - 00005h
> was mostly future proofing, we can get away with only reading 6 values.
> the expense is to read 1, any number after that doesnt cost alot. That
> being said sure thing.

With the dpcd read, memcmp, memcpy, and debug logging written based on
sizeof(dpcd_ext), it'll be trivial to just adjust the size of the local
array if needed.

>> Surely this is not XXX 1.2? ;)
> I found it in a dp1.2 spec that Rodrigo had, I had originally found it
> as a change with dp1.3. Earlier versions of the patch that added
> DP_TRAINING_AUX_RD_MASK has had dp1.3 until he showed me that. If you'd
> like Ill change it.

I'm not looking it up now, but please just update the XXX as best you
can.

BR,
Jani.


-- 
Jani Nikula, Intel Open Source Graphics Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
  2018-05-16 16:33 [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT matthew.s.atwood
                   ` (3 preceding siblings ...)
  2018-05-17  1:27 ` ✓ Fi.CI.IGT: success for " Patchwork
@ 2018-06-26  0:39 ` Manasi Navare
  2018-06-26 14:54   ` Atwood, Matthew S
  4 siblings, 1 reply; 12+ messages in thread
From: Manasi Navare @ 2018-06-26  0:39 UTC (permalink / raw)
  To: matthew.s.atwood; +Cc: intel-gfx, paulo.r.zanoni, rodrigo.vivi

What is the status of this patch?
I am hitting this issue with one of the DP 1.4 sinks where the correct
values of DPCD are present at this new offset of 0x2200 else I see
bad values for REV and Max_link_rate etc..
So we absolutely need this for DP 1.4 sinks.

Manasi

On Wed, May 16, 2018 at 09:33:42AM -0700, matthew.s.atwood@intel.com wrote:
> From: Matt Atwood <matthew.s.atwood@intel.com>
> 
> According to DP spec (2.9.3.1 of DP 1.4) if
> EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT is set the addresses in DPCD
> 02200h through 0220Fh shall contain the DPRX's true capability. These
> values will match 00000h through 0000Fh, except for DPCD_REV,
> MAX_LINK_RATE, DOWN_STREAM_PORT_PRESENT.
> 
> Read from DPCD once for all 3 values as this is an expensive operation.
> Spec mentions that all of address space 02200h through 0220Fh should
> contain the right information however currently only 3 values can
> differ.
> 
> There is no address space in the intel_dp->dpcd struct for addresses
> 02200h through 0220Fh, and since so much of the data is a identical,
> simply overwrite the values stored in 00000h through 0000Fh with the
> values that can be overwritten from addresses 02200h through 0220Fh
> 
> Signed-off-by: Matt Atwood <matthew.s.atwood@intel.com>
> ---
>  drivers/gpu/drm/i915/intel_dp.c | 14 ++++++++++++++
>  include/drm/drm_dp_helper.h     |  5 +++--
>  2 files changed, 17 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
> index dde92e4af5d3..899ebc5cece6 100644
> --- a/drivers/gpu/drm/i915/intel_dp.c
> +++ b/drivers/gpu/drm/i915/intel_dp.c
> @@ -3738,6 +3738,20 @@ intel_dp_read_dpcd(struct intel_dp *intel_dp)
>  			     sizeof(intel_dp->dpcd)) < 0)
>  		return false; /* aux transfer failed */
>  
> +	if (intel_dp->dpcd[DP_TRAINING_AUX_RD_INTERVAL] &
> +	    DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT &&
> +	    intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14) {
> +		uint8_t dpcd_ext[16];
> +
> +		if (drm_dp_dpcd_read(&intel_dp->aux, DP_DP13_DPCD_REV,
> +		    &dpcd_ext, sizeof(dpcd_ext)) < 0)
> +			return false; /* aux transfer failed */
> +
> +		intel_dp->dpcd[DP_DPCD_REV] = dpcd_ext[DP_DPCD_REV];
> +		intel_dp->dpcd[DP_MAX_LINK_RATE] = dpcd_ext[DP_MAX_LINK_RATE];
> +		intel_dp->dpcd[DP_DOWNSTREAMPORT_PRESENT] =
> +			dpcd_ext[DP_DOWNSTREAMPORT_PRESENT];
> +	}
>  	DRM_DEBUG_KMS("DPCD: %*ph\n", (int) sizeof(intel_dp->dpcd), intel_dp->dpcd);
>  
>  	return intel_dp->dpcd[DP_DPCD_REV] != 0;
> diff --git a/include/drm/drm_dp_helper.h b/include/drm/drm_dp_helper.h
> index c01564991a9f..757bd5913f3d 100644
> --- a/include/drm/drm_dp_helper.h
> +++ b/include/drm/drm_dp_helper.h
> @@ -123,8 +123,9 @@
>  # define DP_FRAMING_CHANGE_CAP		    (1 << 1)
>  # define DP_DPCD_DISPLAY_CONTROL_CAPABLE     (1 << 3) /* edp v1.2 or higher */
>  
> -#define DP_TRAINING_AUX_RD_INTERVAL         0x00e   /* XXX 1.2? */
> -# define DP_TRAINING_AUX_RD_MASK            0x7F    /* XXX 1.2? */
> +#define DP_TRAINING_AUX_RD_INTERVAL             0x00e   /* XXX 1.2? */
> +# define DP_TRAINING_AUX_RD_MASK                0x7F    /* XXX 1.2? */
> +# define DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT (1 << 7)/* XXX 1.2? */
>  
>  #define DP_ADAPTER_CAP			    0x00f   /* 1.2 */
>  # define DP_FORCE_LOAD_SENSE_CAP	    (1 << 0)
> -- 
> 2.17.0
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
  2018-06-26  0:39 ` [PATCH] " Manasi Navare
@ 2018-06-26 14:54   ` Atwood, Matthew S
  2018-07-10 18:51     ` Manasi Navare
  0 siblings, 1 reply; 12+ messages in thread
From: Atwood, Matthew S @ 2018-06-26 14:54 UTC (permalink / raw)
  To: Navare, Manasi D; +Cc: intel-gfx, Zanoni, Paulo R, Vivi, Rodrigo

ill uprev by EOD
________________________________________
From: Navare, Manasi D
Sent: Monday, June 25, 2018 5:39 PM
To: Atwood, Matthew S
Cc: intel-gfx@lists.freedesktop.org; Vivi, Rodrigo; bleung@chromium.org; Zanoni, Paulo R
Subject: Re: [Intel-gfx] [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT

What is the status of this patch?
I am hitting this issue with one of the DP 1.4 sinks where the correct
values of DPCD are present at this new offset of 0x2200 else I see
bad values for REV and Max_link_rate etc..
So we absolutely need this for DP 1.4 sinks.

Manasi

On Wed, May 16, 2018 at 09:33:42AM -0700, matthew.s.atwood@intel.com wrote:
> From: Matt Atwood <matthew.s.atwood@intel.com>
>
> According to DP spec (2.9.3.1 of DP 1.4) if
> EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT is set the addresses in DPCD
> 02200h through 0220Fh shall contain the DPRX's true capability. These
> values will match 00000h through 0000Fh, except for DPCD_REV,
> MAX_LINK_RATE, DOWN_STREAM_PORT_PRESENT.
>
> Read from DPCD once for all 3 values as this is an expensive operation.
> Spec mentions that all of address space 02200h through 0220Fh should
> contain the right information however currently only 3 values can
> differ.
>
> There is no address space in the intel_dp->dpcd struct for addresses
> 02200h through 0220Fh, and since so much of the data is a identical,
> simply overwrite the values stored in 00000h through 0000Fh with the
> values that can be overwritten from addresses 02200h through 0220Fh
>
> Signed-off-by: Matt Atwood <matthew.s.atwood@intel.com>
> ---
>  drivers/gpu/drm/i915/intel_dp.c | 14 ++++++++++++++
>  include/drm/drm_dp_helper.h     |  5 +++--
>  2 files changed, 17 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
> index dde92e4af5d3..899ebc5cece6 100644
> --- a/drivers/gpu/drm/i915/intel_dp.c
> +++ b/drivers/gpu/drm/i915/intel_dp.c
> @@ -3738,6 +3738,20 @@ intel_dp_read_dpcd(struct intel_dp *intel_dp)
>                            sizeof(intel_dp->dpcd)) < 0)
>               return false; /* aux transfer failed */
>
> +     if (intel_dp->dpcd[DP_TRAINING_AUX_RD_INTERVAL] &
> +         DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT &&
> +         intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14) {
> +             uint8_t dpcd_ext[16];
> +
> +             if (drm_dp_dpcd_read(&intel_dp->aux, DP_DP13_DPCD_REV,
> +                 &dpcd_ext, sizeof(dpcd_ext)) < 0)
> +                     return false; /* aux transfer failed */
> +
> +             intel_dp->dpcd[DP_DPCD_REV] = dpcd_ext[DP_DPCD_REV];
> +             intel_dp->dpcd[DP_MAX_LINK_RATE] = dpcd_ext[DP_MAX_LINK_RATE];
> +             intel_dp->dpcd[DP_DOWNSTREAMPORT_PRESENT] =
> +                     dpcd_ext[DP_DOWNSTREAMPORT_PRESENT];
> +     }
>       DRM_DEBUG_KMS("DPCD: %*ph\n", (int) sizeof(intel_dp->dpcd), intel_dp->dpcd);
>
>       return intel_dp->dpcd[DP_DPCD_REV] != 0;
> diff --git a/include/drm/drm_dp_helper.h b/include/drm/drm_dp_helper.h
> index c01564991a9f..757bd5913f3d 100644
> --- a/include/drm/drm_dp_helper.h
> +++ b/include/drm/drm_dp_helper.h
> @@ -123,8 +123,9 @@
>  # define DP_FRAMING_CHANGE_CAP                   (1 << 1)
>  # define DP_DPCD_DISPLAY_CONTROL_CAPABLE     (1 << 3) /* edp v1.2 or higher */
>
> -#define DP_TRAINING_AUX_RD_INTERVAL         0x00e   /* XXX 1.2? */
> -# define DP_TRAINING_AUX_RD_MASK            0x7F    /* XXX 1.2? */
> +#define DP_TRAINING_AUX_RD_INTERVAL             0x00e   /* XXX 1.2? */
> +# define DP_TRAINING_AUX_RD_MASK                0x7F    /* XXX 1.2? */
> +# define DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT (1 << 7)/* XXX 1.2? */
>
>  #define DP_ADAPTER_CAP                           0x00f   /* 1.2 */
>  # define DP_FORCE_LOAD_SENSE_CAP         (1 << 0)
> --
> 2.17.0
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
  2018-06-26 14:54   ` Atwood, Matthew S
@ 2018-07-10 18:51     ` Manasi Navare
  0 siblings, 0 replies; 12+ messages in thread
From: Manasi Navare @ 2018-07-10 18:51 UTC (permalink / raw)
  To: Atwood, Matthew S; +Cc: intel-gfx, Zanoni, Paulo R, Vivi, Rodrigo

Matt, is the new revision already submitted to the M-L?

Manasi

On Tue, Jun 26, 2018 at 07:54:19AM -0700, Atwood, Matthew S wrote:
> ill uprev by EOD
> ________________________________________
> From: Navare, Manasi D
> Sent: Monday, June 25, 2018 5:39 PM
> To: Atwood, Matthew S
> Cc: intel-gfx@lists.freedesktop.org; Vivi, Rodrigo; bleung@chromium.org; Zanoni, Paulo R
> Subject: Re: [Intel-gfx] [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT
> 
> What is the status of this patch?
> I am hitting this issue with one of the DP 1.4 sinks where the correct
> values of DPCD are present at this new offset of 0x2200 else I see
> bad values for REV and Max_link_rate etc..
> So we absolutely need this for DP 1.4 sinks.
> 
> Manasi
> 
> On Wed, May 16, 2018 at 09:33:42AM -0700, matthew.s.atwood@intel.com wrote:
> > From: Matt Atwood <matthew.s.atwood@intel.com>
> >
> > According to DP spec (2.9.3.1 of DP 1.4) if
> > EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT is set the addresses in DPCD
> > 02200h through 0220Fh shall contain the DPRX's true capability. These
> > values will match 00000h through 0000Fh, except for DPCD_REV,
> > MAX_LINK_RATE, DOWN_STREAM_PORT_PRESENT.
> >
> > Read from DPCD once for all 3 values as this is an expensive operation.
> > Spec mentions that all of address space 02200h through 0220Fh should
> > contain the right information however currently only 3 values can
> > differ.
> >
> > There is no address space in the intel_dp->dpcd struct for addresses
> > 02200h through 0220Fh, and since so much of the data is a identical,
> > simply overwrite the values stored in 00000h through 0000Fh with the
> > values that can be overwritten from addresses 02200h through 0220Fh
> >
> > Signed-off-by: Matt Atwood <matthew.s.atwood@intel.com>
> > ---
> >  drivers/gpu/drm/i915/intel_dp.c | 14 ++++++++++++++
> >  include/drm/drm_dp_helper.h     |  5 +++--
> >  2 files changed, 17 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
> > index dde92e4af5d3..899ebc5cece6 100644
> > --- a/drivers/gpu/drm/i915/intel_dp.c
> > +++ b/drivers/gpu/drm/i915/intel_dp.c
> > @@ -3738,6 +3738,20 @@ intel_dp_read_dpcd(struct intel_dp *intel_dp)
> >                            sizeof(intel_dp->dpcd)) < 0)
> >               return false; /* aux transfer failed */
> >
> > +     if (intel_dp->dpcd[DP_TRAINING_AUX_RD_INTERVAL] &
> > +         DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT &&
> > +         intel_dp->dpcd[DP_DPCD_REV] >= DP_DPCD_REV_14) {
> > +             uint8_t dpcd_ext[16];
> > +
> > +             if (drm_dp_dpcd_read(&intel_dp->aux, DP_DP13_DPCD_REV,
> > +                 &dpcd_ext, sizeof(dpcd_ext)) < 0)
> > +                     return false; /* aux transfer failed */
> > +
> > +             intel_dp->dpcd[DP_DPCD_REV] = dpcd_ext[DP_DPCD_REV];
> > +             intel_dp->dpcd[DP_MAX_LINK_RATE] = dpcd_ext[DP_MAX_LINK_RATE];
> > +             intel_dp->dpcd[DP_DOWNSTREAMPORT_PRESENT] =
> > +                     dpcd_ext[DP_DOWNSTREAMPORT_PRESENT];
> > +     }
> >       DRM_DEBUG_KMS("DPCD: %*ph\n", (int) sizeof(intel_dp->dpcd), intel_dp->dpcd);
> >
> >       return intel_dp->dpcd[DP_DPCD_REV] != 0;
> > diff --git a/include/drm/drm_dp_helper.h b/include/drm/drm_dp_helper.h
> > index c01564991a9f..757bd5913f3d 100644
> > --- a/include/drm/drm_dp_helper.h
> > +++ b/include/drm/drm_dp_helper.h
> > @@ -123,8 +123,9 @@
> >  # define DP_FRAMING_CHANGE_CAP                   (1 << 1)
> >  # define DP_DPCD_DISPLAY_CONTROL_CAPABLE     (1 << 3) /* edp v1.2 or higher */
> >
> > -#define DP_TRAINING_AUX_RD_INTERVAL         0x00e   /* XXX 1.2? */
> > -# define DP_TRAINING_AUX_RD_MASK            0x7F    /* XXX 1.2? */
> > +#define DP_TRAINING_AUX_RD_INTERVAL             0x00e   /* XXX 1.2? */
> > +# define DP_TRAINING_AUX_RD_MASK                0x7F    /* XXX 1.2? */
> > +# define DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT (1 << 7)/* XXX 1.2? */
> >
> >  #define DP_ADAPTER_CAP                           0x00f   /* 1.2 */
> >  # define DP_FORCE_LOAD_SENSE_CAP         (1 << 0)
> > --
> > 2.17.0
> >
> > _______________________________________________
> > Intel-gfx mailing list
> > Intel-gfx@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/intel-gfx
> 
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2018-07-10 18:49 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-16 16:33 [PATCH] drm/dp: implement EXTENDED_RECEIVER_CAPABILITY_FIELD_PRESENT matthew.s.atwood
2018-05-16 17:17 ` ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
2018-05-16 17:33 ` ✓ Fi.CI.BAT: success " Patchwork
2018-05-16 22:31 ` [PATCH] " Dhinakaran Pandiyan
2018-05-16 22:23   ` Manasi Navare
2018-05-17  9:50   ` Jani Nikula
2018-05-17 15:29     ` Atwood, Matthew S
2018-05-17 17:53       ` Jani Nikula
2018-05-17  1:27 ` ✓ Fi.CI.IGT: success for " Patchwork
2018-06-26  0:39 ` [PATCH] " Manasi Navare
2018-06-26 14:54   ` Atwood, Matthew S
2018-07-10 18:51     ` Manasi Navare

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.