intel-gfx.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* i915 TV fixes
@ 2011-04-12  5:51 Chris Wilson
  2011-04-12  5:51 ` [PATCH 1/3] drm/i915/tv: Remember the detected TV type Chris Wilson
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Chris Wilson @ 2011-04-12  5:51 UTC (permalink / raw)
  To: intel-gfx

The hardware does exist! I thought it was just an elaborate myth in the
docs, but we have been fortunate that people have not only run into a
few regressions but also diagnosed and sent patches for them.
-Chris

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

* [PATCH 1/3] drm/i915/tv: Remember the detected TV type
  2011-04-12  5:51 i915 TV fixes Chris Wilson
@ 2011-04-12  5:51 ` Chris Wilson
  2011-04-12  8:34   ` Paul Menzel
  2011-04-12  5:51 ` [PATCH 2/3] drm/i915/tv: Only poll for TV connections Chris Wilson
  2011-04-12  5:51 ` [PATCH 3/3] drm/i915/tv: Fix modeset flickering introduced in 7f58aabc3 Chris Wilson
  2 siblings, 1 reply; 8+ messages in thread
From: Chris Wilson @ 2011-04-12  5:51 UTC (permalink / raw)
  To: intel-gfx; +Cc: Mathew McKernan, stable, Chris Wilson

From: Mathew McKernan <matmckernan@rauland.com.au>

During detect() we would probe the connection bits to determine if
there was a TV attached, and what video input type (Component, S-Video,
Composite, etc) to use. However, we promptly discarded this vital bit of
information and never propagated it to where it was used to determine
the correct modes and setup the control registers. Fix it!

This fixes a regression from 7b334fcb45b757ffb093696ca3de1b0c8b4a33f1.

Reported-and-tested-by: Mathew McKernan <matmckernan@rauland.com.au>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=35977
Signed-off-by: Mathew McKernan <matmckernan@rauland.com.au>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: stable@kernel.org
---
 drivers/gpu/drm/i915/intel_tv.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_tv.c b/drivers/gpu/drm/i915/intel_tv.c
index c27887f..84a733b 100644
--- a/drivers/gpu/drm/i915/intel_tv.c
+++ b/drivers/gpu/drm/i915/intel_tv.c
@@ -1356,7 +1356,9 @@ intel_tv_detect(struct drm_connector *connector, bool force)
 	if (type < 0)
 		return connector_status_disconnected;
 
+	intel_tv->type = type;
 	intel_tv_find_better_format(connector);
+
 	return connector_status_connected;
 }
 
-- 
1.7.4.1

_______________________________________________
stable mailing list
stable@linux.kernel.org
http://linux.kernel.org/mailman/listinfo/stable

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

* [PATCH 2/3] drm/i915/tv: Only poll for TV connections
  2011-04-12  5:51 i915 TV fixes Chris Wilson
  2011-04-12  5:51 ` [PATCH 1/3] drm/i915/tv: Remember the detected TV type Chris Wilson
@ 2011-04-12  5:51 ` Chris Wilson
  2011-04-12  5:51 ` [PATCH 3/3] drm/i915/tv: Fix modeset flickering introduced in 7f58aabc3 Chris Wilson
  2 siblings, 0 replies; 8+ messages in thread
From: Chris Wilson @ 2011-04-12  5:51 UTC (permalink / raw)
  To: intel-gfx

From: Mathew McKernan <matmckernan@rauland.com.au>

As a probe for a TV connection modifies the TV_CTL register, it causes a
loss of sync and a regular glitch on the output. This is highly
undesirable when using the TV, so only poll for TV connections and wait
for an explicit query for detecting the disconnection event.

Reported-by: Mathew McKernan <matmckernan@rauland.com.au>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=35977
Signed-off-by: Mathew McKernan <matmckernan@rauland.com.au>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
 drivers/gpu/drm/i915/intel_tv.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_tv.c b/drivers/gpu/drm/i915/intel_tv.c
index 84a733b..abd5444 100644
--- a/drivers/gpu/drm/i915/intel_tv.c
+++ b/drivers/gpu/drm/i915/intel_tv.c
@@ -1650,8 +1650,7 @@ intel_tv_init(struct drm_device *dev)
 	 *
 	 * More recent chipsets favour HDMI rather than integrated S-Video.
 	 */
-	connector->polled =
-		DRM_CONNECTOR_POLL_CONNECT | DRM_CONNECTOR_POLL_DISCONNECT;
+	connector->polled = DRM_CONNECTOR_POLL_CONNECT;
 
 	drm_connector_init(dev, connector, &intel_tv_connector_funcs,
 			   DRM_MODE_CONNECTOR_SVIDEO);
-- 
1.7.4.1

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

* [PATCH 3/3] drm/i915/tv: Fix modeset flickering introduced in 7f58aabc3
  2011-04-12  5:51 i915 TV fixes Chris Wilson
  2011-04-12  5:51 ` [PATCH 1/3] drm/i915/tv: Remember the detected TV type Chris Wilson
  2011-04-12  5:51 ` [PATCH 2/3] drm/i915/tv: Only poll for TV connections Chris Wilson
@ 2011-04-12  5:51 ` Chris Wilson
  2011-04-12 15:16   ` Jesse Barnes
  2 siblings, 1 reply; 8+ messages in thread
From: Chris Wilson @ 2011-04-12  5:51 UTC (permalink / raw)
  To: intel-gfx; +Cc: Sitsofe Wheeler

From: Sitsofe Wheeler <sitsofe@yahoo.com>

The tidy ups in 7f58aabc369014fda3a4a33604ba0a1b63b941ac ("drm/i915:
cleanup per-pipe reg usage") changed intel_crtc->plane to intel_crtc->pipe in
intel_tv_mode_set(). This caused the screen to quickly turn off before
returning whenever modesetting/mode probing took place on my 915GM EeePC
900 creating a flickering effect. This patch changes intel_crtc->pipe back
to intel_crtc->plane which solves the problem for me.

References: https://bugs.freedesktop.org/show_bug.cgi?id=35903
Signed-off-by: Sitsofe Wheeler <sitsofe@yahoo.com>
Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
 drivers/gpu/drm/i915/intel_tv.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_tv.c b/drivers/gpu/drm/i915/intel_tv.c
index abd5444..2f7c084 100644
--- a/drivers/gpu/drm/i915/intel_tv.c
+++ b/drivers/gpu/drm/i915/intel_tv.c
@@ -1131,10 +1131,10 @@ intel_tv_mode_set(struct drm_encoder *encoder, struct drm_display_mode *mode,
 			    (video_levels->blank << TV_BLANK_LEVEL_SHIFT)));
 	{
 		int pipeconf_reg = PIPECONF(pipe);
-		int dspcntr_reg = DSPCNTR(pipe);
+		int dspcntr_reg = DSPCNTR(intel_crtc->plane);
 		int pipeconf = I915_READ(pipeconf_reg);
 		int dspcntr = I915_READ(dspcntr_reg);
-		int dspbase_reg = DSPADDR(pipe);
+		int dspbase_reg = DSPADDR(intel_crtc->plane);
 		int xpos = 0x0, ypos = 0x0;
 		unsigned int xsize, ysize;
 		/* Pipe must be off here */
-- 
1.7.4.1

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

* Re: [PATCH 1/3] drm/i915/tv: Remember the detected TV type
  2011-04-12  5:51 ` [PATCH 1/3] drm/i915/tv: Remember the detected TV type Chris Wilson
@ 2011-04-12  8:34   ` Paul Menzel
  2011-04-12  8:43     ` Chris Wilson
  0 siblings, 1 reply; 8+ messages in thread
From: Paul Menzel @ 2011-04-12  8:34 UTC (permalink / raw)
  To: intel-gfx


[-- Attachment #1.1: Type: text/plain, Size: 1177 bytes --]

Am Dienstag, den 12.04.2011, 06:51 +0100 schrieb Chris Wilson:
> From: Mathew McKernan <matmckernan@rauland.com.au>
> 
> During detect() we would probe the connection bits to determine if
> there was a TV attached, and what video input type (Component, S-Video,
> Composite, etc) to use. However, we promptly discarded this vital bit of
> information and never propagated it to where it was used to determine
> the correct modes and setup the control registers. Fix it!
> 
> This fixes a regression from 7b334fcb45b757ffb093696ca3de1b0c8b4a33f1.

To quote Mark Brown [1].

        Always include the subject line of the commit in patches -
        readers are unlikely to have memorised commit IDs.

> Reported-and-tested-by: Mathew McKernan <matmckernan@rauland.com.au>
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=35977
> Signed-off-by: Mathew McKernan <matmckernan@rauland.com.au>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: stable@kernel.org

Acked-by: Paul Menzel <paulepanter@users.sourceforge.net>

[…]


Thanks,

Paul


[1] http://mailman.alsa-project.org/pipermail/alsa-devel/2011-February/037200.html

[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

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

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

* Re: [PATCH 1/3] drm/i915/tv: Remember the detected TV type
  2011-04-12  8:34   ` Paul Menzel
@ 2011-04-12  8:43     ` Chris Wilson
  2011-04-12  9:21       ` Paul Menzel
  0 siblings, 1 reply; 8+ messages in thread
From: Chris Wilson @ 2011-04-12  8:43 UTC (permalink / raw)
  To: Paul Menzel, intel-gfx

On Tue, 12 Apr 2011 10:34:41 +0200, Paul Menzel <paulepanter@users.sourceforge.net> wrote:
> Am Dienstag, den 12.04.2011, 06:51 +0100 schrieb Chris Wilson:
> > This fixes a regression from 7b334fcb45b757ffb093696ca3de1b0c8b4a33f1.
> 
> To quote Mark Brown [1].
> 
>         Always include the subject line of the commit in patches -
>         readers are unlikely to have memorised commit IDs.

Does it really help to include the subject as well? I suppose it will help
in the case where the patch has been cherry-picked into other trees,
stable for instance. However, I truly didn't expect anyone to remember the
original commit as the first thing I do is to read through the identified
commit to try and understand the subsequent patch in context.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre

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

* Re: [PATCH 1/3] drm/i915/tv: Remember the detected TV type
  2011-04-12  8:43     ` Chris Wilson
@ 2011-04-12  9:21       ` Paul Menzel
  0 siblings, 0 replies; 8+ messages in thread
From: Paul Menzel @ 2011-04-12  9:21 UTC (permalink / raw)
  To: intel-gfx


[-- Attachment #1.1: Type: text/plain, Size: 948 bytes --]

Am Dienstag, den 12.04.2011, 09:43 +0100 schrieb Chris Wilson:
> On Tue, 12 Apr 2011 10:34:41 +0200, Paul Menzel <paulepanter@users.sourceforge.net> wrote:
> > Am Dienstag, den 12.04.2011, 06:51 +0100 schrieb Chris Wilson:
> > > This fixes a regression from 7b334fcb45b757ffb093696ca3de1b0c8b4a33f1.
> > 
> > To quote Mark Brown [1].
> > 
> >         Always include the subject line of the commit in patches -
> >         readers are unlikely to have memorised commit IDs.
> 
> Does it really help to include the subject as well? I suppose it will help
> in the case where the patch has been cherry-picked into other trees,
> stable for instance. However, I truly didn't expect anyone to remember the
> original commit as the first thing I do is to read through the identified
> commit to try and understand the subsequent patch in context.

In my opinion the reason is especially the first one you mentioned.


Thanks,

Paul

[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

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

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

* Re: [PATCH 3/3] drm/i915/tv: Fix modeset flickering introduced in 7f58aabc3
  2011-04-12  5:51 ` [PATCH 3/3] drm/i915/tv: Fix modeset flickering introduced in 7f58aabc3 Chris Wilson
@ 2011-04-12 15:16   ` Jesse Barnes
  0 siblings, 0 replies; 8+ messages in thread
From: Jesse Barnes @ 2011-04-12 15:16 UTC (permalink / raw)
  To: Chris Wilson; +Cc: intel-gfx, Sitsofe Wheeler

On Tue, 12 Apr 2011 06:51:39 +0100
Chris Wilson <chris@chris-wilson.co.uk> wrote:

> From: Sitsofe Wheeler <sitsofe@yahoo.com>
> 
> The tidy ups in 7f58aabc369014fda3a4a33604ba0a1b63b941ac ("drm/i915:
> cleanup per-pipe reg usage") changed intel_crtc->plane to intel_crtc->pipe in
> intel_tv_mode_set(). This caused the screen to quickly turn off before
> returning whenever modesetting/mode probing took place on my 915GM EeePC
> 900 creating a flickering effect. This patch changes intel_crtc->pipe back
> to intel_crtc->plane which solves the problem for me.
> 
> References: https://bugs.freedesktop.org/show_bug.cgi?id=35903
> Signed-off-by: Sitsofe Wheeler <sitsofe@yahoo.com>
> Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> ---
>  drivers/gpu/drm/i915/intel_tv.c |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)

Doh!  Thanks Sitsofe.

Humbly-acked-by: Jesse Barnes <jbarnes@virtuousgeek.org>

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

end of thread, other threads:[~2011-04-12 15:16 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-04-12  5:51 i915 TV fixes Chris Wilson
2011-04-12  5:51 ` [PATCH 1/3] drm/i915/tv: Remember the detected TV type Chris Wilson
2011-04-12  8:34   ` Paul Menzel
2011-04-12  8:43     ` Chris Wilson
2011-04-12  9:21       ` Paul Menzel
2011-04-12  5:51 ` [PATCH 2/3] drm/i915/tv: Only poll for TV connections Chris Wilson
2011-04-12  5:51 ` [PATCH 3/3] drm/i915/tv: Fix modeset flickering introduced in 7f58aabc3 Chris Wilson
2011-04-12 15:16   ` Jesse Barnes

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).