diff mbox series

drm/i915/dp: Fix incorrect test parameter for DP link layer compliance

Message ID 20200103150737.17934-1-shawn.c.lee@intel.com (mailing list archive)
State New, archived
Headers show
Series drm/i915/dp: Fix incorrect test parameter for DP link layer compliance | expand

Commit Message

Lee, Shawn C Jan. 3, 2020, 3:07 p.m. UTC
Run intel_dp_compliance would failed at video pattern related
test case sometimes. DP test applet read incorrect test type
from kernel to cause this symptom. Add a "\n" (newline) in
seq_printf() then DP test applet will get proper parameters.

Cc: Manasi Navare <manasi.d.navare@intel.com>
Cc: Jani Nikula <jani.nikula@linux.intel.com>
Cc: Daniel Vetter <daniel.vetter@intel.com>
Cc: Ville Syrjala <ville.syrjala@linux.intel.com>
Cc: Cooper Chiou <cooper.chiou@intel.com>
Signed-off-by: Lee Shawn C <shawn.c.lee@intel.com>
---
 drivers/gpu/drm/i915/i915_debugfs.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Jani Nikula Jan. 3, 2020, 9:03 a.m. UTC | #1
On Fri, 03 Jan 2020, Lee Shawn C <shawn.c.lee@intel.com> wrote:
> Run intel_dp_compliance would failed at video pattern related
> test case sometimes. DP test applet read incorrect test type
> from kernel to cause this symptom. Add a "\n" (newline) in
> seq_printf() then DP test applet will get proper parameters.
>
> Cc: Manasi Navare <manasi.d.navare@intel.com>
> Cc: Jani Nikula <jani.nikula@linux.intel.com>
> Cc: Daniel Vetter <daniel.vetter@intel.com>
> Cc: Ville Syrjala <ville.syrjala@linux.intel.com>
> Cc: Cooper Chiou <cooper.chiou@intel.com>
> Signed-off-by: Lee Shawn C <shawn.c.lee@intel.com>

Fixes: eb3394faeb97 ("drm/i915: Add debugfs test control files for Displayport compliance testing")
Reviewed-by: Jani Nikula <jani.nikula@intel.com>

> ---
>  drivers/gpu/drm/i915/i915_debugfs.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
> index 0ac98e39eb75..74180158a909 100644
> --- a/drivers/gpu/drm/i915/i915_debugfs.c
> +++ b/drivers/gpu/drm/i915/i915_debugfs.c
> @@ -3167,7 +3167,7 @@ static int i915_displayport_test_data_show(struct seq_file *m, void *data)
>  			intel_dp = enc_to_intel_dp(&encoder->base);
>  			if (intel_dp->compliance.test_type ==
>  			    DP_TEST_LINK_EDID_READ)
> -				seq_printf(m, "%lx",
> +				seq_printf(m, "%lx\n",
>  					   intel_dp->compliance.test_data.edid);
>  			else if (intel_dp->compliance.test_type ==
>  				 DP_TEST_LINK_VIDEO_PATTERN) {
> @@ -3209,7 +3209,7 @@ static int i915_displayport_test_type_show(struct seq_file *m, void *data)
>  
>  		if (encoder && connector->status == connector_status_connected) {
>  			intel_dp = enc_to_intel_dp(&encoder->base);
> -			seq_printf(m, "%02lx", intel_dp->compliance.test_type);
> +			seq_printf(m, "%02lx\n", intel_dp->compliance.test_type);
>  		} else
>  			seq_puts(m, "0");
>  	}
Navare, Manasi Jan. 3, 2020, 9:01 p.m. UTC | #2
On Fri, Jan 03, 2020 at 11:07:37PM +0800, Lee Shawn C wrote:
> Run intel_dp_compliance would failed at video pattern related
> test case sometimes. DP test applet read incorrect test type
> from kernel to cause this symptom. Add a "\n" (newline) in
> seq_printf() then DP test applet will get proper parameters.
> 
> Cc: Manasi Navare <manasi.d.navare@intel.com>
> Cc: Jani Nikula <jani.nikula@linux.intel.com>
> Cc: Daniel Vetter <daniel.vetter@intel.com>
> Cc: Ville Syrjala <ville.syrjala@linux.intel.com>
> Cc: Cooper Chiou <cooper.chiou@intel.com>
> Signed-off-by: Lee Shawn C <shawn.c.lee@intel.com

Thank you for fixing this,

Reviewed-by: Manasi Navare <manasi.d.navare@intel.com>

Manasi

>
> ---
>  drivers/gpu/drm/i915/i915_debugfs.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
> index 0ac98e39eb75..74180158a909 100644
> --- a/drivers/gpu/drm/i915/i915_debugfs.c
> +++ b/drivers/gpu/drm/i915/i915_debugfs.c
> @@ -3167,7 +3167,7 @@ static int i915_displayport_test_data_show(struct seq_file *m, void *data)
>  			intel_dp = enc_to_intel_dp(&encoder->base);
>  			if (intel_dp->compliance.test_type ==
>  			    DP_TEST_LINK_EDID_READ)
> -				seq_printf(m, "%lx",
> +				seq_printf(m, "%lx\n",
>  					   intel_dp->compliance.test_data.edid);
>  			else if (intel_dp->compliance.test_type ==
>  				 DP_TEST_LINK_VIDEO_PATTERN) {
> @@ -3209,7 +3209,7 @@ static int i915_displayport_test_type_show(struct seq_file *m, void *data)
>  
>  		if (encoder && connector->status == connector_status_connected) {
>  			intel_dp = enc_to_intel_dp(&encoder->base);
> -			seq_printf(m, "%02lx", intel_dp->compliance.test_type);
> +			seq_printf(m, "%02lx\n", intel_dp->compliance.test_type);
>  		} else
>  			seq_puts(m, "0");
>  	}
> -- 
> 2.17.1
>
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
index 0ac98e39eb75..74180158a909 100644
--- a/drivers/gpu/drm/i915/i915_debugfs.c
+++ b/drivers/gpu/drm/i915/i915_debugfs.c
@@ -3167,7 +3167,7 @@  static int i915_displayport_test_data_show(struct seq_file *m, void *data)
 			intel_dp = enc_to_intel_dp(&encoder->base);
 			if (intel_dp->compliance.test_type ==
 			    DP_TEST_LINK_EDID_READ)
-				seq_printf(m, "%lx",
+				seq_printf(m, "%lx\n",
 					   intel_dp->compliance.test_data.edid);
 			else if (intel_dp->compliance.test_type ==
 				 DP_TEST_LINK_VIDEO_PATTERN) {
@@ -3209,7 +3209,7 @@  static int i915_displayport_test_type_show(struct seq_file *m, void *data)
 
 		if (encoder && connector->status == connector_status_connected) {
 			intel_dp = enc_to_intel_dp(&encoder->base);
-			seq_printf(m, "%02lx", intel_dp->compliance.test_type);
+			seq_printf(m, "%02lx\n", intel_dp->compliance.test_type);
 		} else
 			seq_puts(m, "0");
 	}