dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm/i915: Explicit the connector name for DP link training result
@ 2017-07-17 14:27 Paul Kocialkowski
  2017-07-18  7:38 ` Jani Nikula
  0 siblings, 1 reply; 3+ messages in thread
From: Paul Kocialkowski @ 2017-07-17 14:27 UTC (permalink / raw)
  To: intel-gfx, dri-devel, linux-kernel; +Cc: Daniel Vetter, David Airlie

This adds the connector name when printing a debug message about the DP
link training result. It is useful to figure out what connector is
failing when multiple DP connectors are used.

Signed-off-by: Paul Kocialkowski <paul.kocialkowski@linux.intel.com>
---
 drivers/gpu/drm/i915/intel_dp_link_training.c | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_dp_link_training.c b/drivers/gpu/drm/i915/intel_dp_link_training.c
index b79c1c0e404c..75a411c94ce5 100644
--- a/drivers/gpu/drm/i915/intel_dp_link_training.c
+++ b/drivers/gpu/drm/i915/intel_dp_link_training.c
@@ -321,13 +321,15 @@ intel_dp_start_link_train(struct intel_dp *intel_dp)
 	if (!intel_dp_link_training_channel_equalization(intel_dp))
 		goto failure_handling;
 
-	DRM_DEBUG_KMS("Link Training Passed at Link Rate = %d, Lane count = %d",
-		      intel_dp->link_rate, intel_dp->lane_count);
+	DRM_DEBUG_KMS("Link Training Passed at Link Rate = %d, Lane count = %d for connector %s",
+		      intel_dp->link_rate, intel_dp->lane_count,
+		      intel_connector->base.name);
 	return;
 
  failure_handling:
-	DRM_DEBUG_KMS("Link Training failed at link rate = %d, lane count = %d",
-		      intel_dp->link_rate, intel_dp->lane_count);
+	DRM_DEBUG_KMS("Link Training failed at link rate = %d, lane count = %d for connector %s",
+		      intel_dp->link_rate, intel_dp->lane_count,
+		      intel_connector->base.name);
 	if (!intel_dp_get_link_train_fallback_values(intel_dp,
 						     intel_dp->link_rate,
 						     intel_dp->lane_count))
-- 
2.13.2

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

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

* Re: [PATCH] drm/i915: Explicit the connector name for DP link training result
  2017-07-17 14:27 [PATCH] drm/i915: Explicit the connector name for DP link training result Paul Kocialkowski
@ 2017-07-18  7:38 ` Jani Nikula
  2017-07-18 11:28   ` Paul Kocialkowski
  0 siblings, 1 reply; 3+ messages in thread
From: Jani Nikula @ 2017-07-18  7:38 UTC (permalink / raw)
  To: Paul Kocialkowski, intel-gfx, dri-devel, linux-kernel
  Cc: Daniel Vetter, David Airlie

On Mon, 17 Jul 2017, Paul Kocialkowski <paul.kocialkowski@linux.intel.com> wrote:
> This adds the connector name when printing a debug message about the DP
> link training result. It is useful to figure out what connector is
> failing when multiple DP connectors are used.

Perhaps more consistent would be using a prefix like this:

	DRM_DEBUG_KMS("[CONNECTOR:%d:%s] bla bla blaa\n",
        	connector->base.base.id, connector->base.name);

BR,
Jani.

>
> Signed-off-by: Paul Kocialkowski <paul.kocialkowski@linux.intel.com>
> ---
>  drivers/gpu/drm/i915/intel_dp_link_training.c | 10 ++++++----
>  1 file changed, 6 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_dp_link_training.c b/drivers/gpu/drm/i915/intel_dp_link_training.c
> index b79c1c0e404c..75a411c94ce5 100644
> --- a/drivers/gpu/drm/i915/intel_dp_link_training.c
> +++ b/drivers/gpu/drm/i915/intel_dp_link_training.c
> @@ -321,13 +321,15 @@ intel_dp_start_link_train(struct intel_dp *intel_dp)
>  	if (!intel_dp_link_training_channel_equalization(intel_dp))
>  		goto failure_handling;
>  
> -	DRM_DEBUG_KMS("Link Training Passed at Link Rate = %d, Lane count = %d",
> -		      intel_dp->link_rate, intel_dp->lane_count);
> +	DRM_DEBUG_KMS("Link Training Passed at Link Rate = %d, Lane count = %d for connector %s",
> +		      intel_dp->link_rate, intel_dp->lane_count,
> +		      intel_connector->base.name);
>  	return;
>  
>   failure_handling:
> -	DRM_DEBUG_KMS("Link Training failed at link rate = %d, lane count = %d",
> -		      intel_dp->link_rate, intel_dp->lane_count);
> +	DRM_DEBUG_KMS("Link Training failed at link rate = %d, lane count = %d for connector %s",
> +		      intel_dp->link_rate, intel_dp->lane_count,
> +		      intel_connector->base.name);
>  	if (!intel_dp_get_link_train_fallback_values(intel_dp,
>  						     intel_dp->link_rate,
>  						     intel_dp->lane_count))

-- 
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] 3+ messages in thread

* Re: [PATCH] drm/i915: Explicit the connector name for DP link training result
  2017-07-18  7:38 ` Jani Nikula
@ 2017-07-18 11:28   ` Paul Kocialkowski
  0 siblings, 0 replies; 3+ messages in thread
From: Paul Kocialkowski @ 2017-07-18 11:28 UTC (permalink / raw)
  To: Jani Nikula, intel-gfx, dri-devel, linux-kernel
  Cc: Daniel Vetter, David Airlie

Hey,

On Tue, 2017-07-18 at 10:38 +0300, Jani Nikula wrote:
> On Mon, 17 Jul 2017, Paul Kocialkowski <paul.kocialkowski@linux.intel.
> com> wrote:
> > This adds the connector name when printing a debug message about the
> > DP
> > link training result. It is useful to figure out what connector is
> > failing when multiple DP connectors are used.
> 
> Perhaps more consistent would be using a prefix like this:
> 
> 	DRM_DEBUG_KMS("[CONNECTOR:%d:%s] bla bla blaa\n",
>         	connector->base.base.id, connector->base.name);

You are definitely right, this is what is used all over the place in the
driver, so I should stick to it.

Thanks for the suggestion, I will send out v2 in that direction shortly.

Cheers,

Paul

> > Signed-off-by: Paul Kocialkowski <paul.kocialkowski@linux.intel.com>
> > ---
> >  drivers/gpu/drm/i915/intel_dp_link_training.c | 10 ++++++----
> >  1 file changed, 6 insertions(+), 4 deletions(-)
> > 
> > diff --git a/drivers/gpu/drm/i915/intel_dp_link_training.c
> > b/drivers/gpu/drm/i915/intel_dp_link_training.c
> > index b79c1c0e404c..75a411c94ce5 100644
> > --- a/drivers/gpu/drm/i915/intel_dp_link_training.c
> > +++ b/drivers/gpu/drm/i915/intel_dp_link_training.c
> > @@ -321,13 +321,15 @@ intel_dp_start_link_train(struct intel_dp
> > *intel_dp)
> >  	if (!intel_dp_link_training_channel_equalization(intel_dp))
> >  		goto failure_handling;
> >  
> > -	DRM_DEBUG_KMS("Link Training Passed at Link Rate = %d, Lane
> > count = %d",
> > -		      intel_dp->link_rate, intel_dp->lane_count);
> > +	DRM_DEBUG_KMS("Link Training Passed at Link Rate = %d, Lane
> > count = %d for connector %s",
> > +		      intel_dp->link_rate, intel_dp->lane_count,
> > +		      intel_connector->base.name);
> >  	return;
> >  
> >   failure_handling:
> > -	DRM_DEBUG_KMS("Link Training failed at link rate = %d, lane
> > count = %d",
> > -		      intel_dp->link_rate, intel_dp->lane_count);
> > +	DRM_DEBUG_KMS("Link Training failed at link rate = %d, lane
> > count = %d for connector %s",
> > +		      intel_dp->link_rate, intel_dp->lane_count,
> > +		      intel_connector->base.name);
> >  	if (!intel_dp_get_link_train_fallback_values(intel_dp,
> >  						     intel_dp-
> > >link_rate,
> >  						     intel_dp-
> > >lane_count))
> 
> 
-- 
Paul Kocialkowski <paul.kocialkowski@linux.intel.com>
Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo, Finland
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

end of thread, other threads:[~2017-07-18 11:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-17 14:27 [PATCH] drm/i915: Explicit the connector name for DP link training result Paul Kocialkowski
2017-07-18  7:38 ` Jani Nikula
2017-07-18 11:28   ` Paul Kocialkowski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).