public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915: Look at staged config when fixing pipe_src_w for LVDS
@ 2015-02-26  7:44 Ander Conselvan de Oliveira
  2015-02-26 13:26 ` Daniel Vetter
  2015-02-27 17:41 ` shuang.he
  0 siblings, 2 replies; 3+ messages in thread
From: Ander Conselvan de Oliveira @ 2015-02-26  7:44 UTC (permalink / raw)
  To: intel-gfx; +Cc: Ander Conselvan de Oliveira, ville.syrjala

The code in function intel_crtc_compute_config() that evens pipe_src_w
if necessary would look at the current config instead of the staged one
when deciding if there is an LVDS encoder in use. This could potentially
lead to the value not being updated, if during the modeset a crtc wasn't
driving an LVDS encoder.

Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com>
---

I noticed this while looking for things that need to be changed for
atomic. The patch is only compiled tested.

Ander

 drivers/gpu/drm/i915/intel_display.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index fad5f76..b0f113d 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -5592,7 +5592,7 @@ static int intel_crtc_compute_config(struct intel_crtc *crtc,
 	 * - LVDS dual channel mode
 	 * - Double wide pipe
 	 */
-	if ((intel_pipe_has_type(crtc, INTEL_OUTPUT_LVDS) &&
+	if ((intel_pipe_will_have_type(crtc, INTEL_OUTPUT_LVDS) &&
 	     intel_is_dual_link_lvds(dev)) || pipe_config->double_wide)
 		pipe_config->pipe_src_w &= ~1;
 
-- 
2.1.0

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

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

* Re: [PATCH] drm/i915: Look at staged config when fixing pipe_src_w for LVDS
  2015-02-26  7:44 [PATCH] drm/i915: Look at staged config when fixing pipe_src_w for LVDS Ander Conselvan de Oliveira
@ 2015-02-26 13:26 ` Daniel Vetter
  2015-02-27 17:41 ` shuang.he
  1 sibling, 0 replies; 3+ messages in thread
From: Daniel Vetter @ 2015-02-26 13:26 UTC (permalink / raw)
  To: Ander Conselvan de Oliveira; +Cc: intel-gfx, ville.syrjala

On Thu, Feb 26, 2015 at 09:44:45AM +0200, Ander Conselvan de Oliveira wrote:
> The code in function intel_crtc_compute_config() that evens pipe_src_w
> if necessary would look at the current config instead of the staged one
> when deciding if there is an LVDS encoder in use. This could potentially
> lead to the value not being updated, if during the modeset a crtc wasn't
> driving an LVDS encoder.
> 
> Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com>

Queued for -next, thanks for the patch.
-Daniel
> ---
> 
> I noticed this while looking for things that need to be changed for
> atomic. The patch is only compiled tested.
> 
> Ander
> 
>  drivers/gpu/drm/i915/intel_display.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index fad5f76..b0f113d 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -5592,7 +5592,7 @@ static int intel_crtc_compute_config(struct intel_crtc *crtc,
>  	 * - LVDS dual channel mode
>  	 * - Double wide pipe
>  	 */
> -	if ((intel_pipe_has_type(crtc, INTEL_OUTPUT_LVDS) &&
> +	if ((intel_pipe_will_have_type(crtc, INTEL_OUTPUT_LVDS) &&
>  	     intel_is_dual_link_lvds(dev)) || pipe_config->double_wide)
>  		pipe_config->pipe_src_w &= ~1;
>  
> -- 
> 2.1.0
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [PATCH] drm/i915: Look at staged config when fixing pipe_src_w for LVDS
  2015-02-26  7:44 [PATCH] drm/i915: Look at staged config when fixing pipe_src_w for LVDS Ander Conselvan de Oliveira
  2015-02-26 13:26 ` Daniel Vetter
@ 2015-02-27 17:41 ` shuang.he
  1 sibling, 0 replies; 3+ messages in thread
From: shuang.he @ 2015-02-27 17:41 UTC (permalink / raw)
  To: shuang.he, ethan.gao, intel-gfx, ander.conselvan.de.oliveira

Tested-By: PRC QA PRTS (Patch Regression Test System Contact: shuang.he@intel.com)
Task id: 5831
-------------------------------------Summary-------------------------------------
Platform          Delta          drm-intel-nightly          Series Applied
PNV                                  282/282              282/282
ILK                                  308/308              308/308
SNB                 -1              326/326              325/326
IVB                                  379/379              379/379
BYT                                  294/294              294/294
HSW                                  387/387              387/387
BDW                 -1              316/316              315/316
-------------------------------------Detailed-------------------------------------
Platform  Test                                drm-intel-nightly          Series Applied
*SNB  igt_kms_pipe_crc_basic_read-crc-pipe-A-frame-sequence      PASS(3)      DMESG_WARN(1)PASS(1)
*BDW  igt_gem_gtt_hog      PASS(2)      DMESG_WARN(1)PASS(1)
Note: You need to pay more attention to line start with '*'
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

end of thread, other threads:[~2015-02-27 17:41 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-26  7:44 [PATCH] drm/i915: Look at staged config when fixing pipe_src_w for LVDS Ander Conselvan de Oliveira
2015-02-26 13:26 ` Daniel Vetter
2015-02-27 17:41 ` shuang.he

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox