From: Pasi =?iso-8859-1?Q?K=E4rkk=E4inen?= Subject: Re: [RFC PATCH] Re: KMS:RV635:Radeon 3650HD graphics driver broken on a laptop when connected to a docking station and external display Date: Thu, 1 Jul 2010 17:47:14 +0300 Message-ID: <20100701144714.GN17817@reaktio.net> References: <20100618184522.GY17817@reaktio.net> <20100619192453.GS17817@reaktio.net> <20100621092310.GD17817@reaktio.net> <20100621093122.GE17817@reaktio.net> <20100621124544.GD2350@barney.localdomain> <20100621181801.GO17817@reaktio.net> <20100701140701.GK17817@reaktio.net> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: Received: from ydin.reaktio.net (reaktio.net [194.89.68.22]) by gabe.freedesktop.org (Postfix) with ESMTP id 6AA8E9E947 for ; Thu, 1 Jul 2010 07:47:12 -0700 (PDT) Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org Errors-To: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org To: Alex Deucher Cc: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org On Thu, Jul 01, 2010 at 10:35:34AM -0400, Alex Deucher wrote: > On Thu, Jul 1, 2010 at 10:07 AM, Pasi K=E4rkk=E4inen wrote: > > On Mon, Jun 21, 2010 at 09:18:01PM +0300, Pasi K=E4rkk=E4inen wrote: > >> > >> > >> > >> I am not sure your patch is right, my guess is that devices field= of > >> > >> radeon connector structure btw the HDMI & DVI connector are diffe= rent > >> > >> and thus that drm_detect_hdmi_monitor is not call. I expect it's = normal > >> > >> for the device field to be different (my understanding being that= HDMI > >> > >> will have one more bit set than the DVI connector). Bottom line is > >> > >> i think we want to discard non hdmi connector just in case we face > >> > >> shared connector. > >> > >> > >> > >> Alex would have to comment on the device field test, maybe your a= tombios > >> > >> is broken. Does it works if instead of removing > >> > >> if (connector =3D=3D list_connector) > >> > >> =A0 =A0 =A0 =A0continue; > >> > >> You remove : > >> > >> if (radeon_connector->devices =3D=3D list_radeon_connector->devic= es) > >> > >> > >> > >> Also can you print the radeon_connector->devices of all your conn= ector > >> > >> so we can compare them. > >> > > > >> > > The code was for systems with shared ddc lines and shared encoders, > >> > > but it looks like your system may have a shared ddc line and (sort= of) > >> > > non-shared encoders. =A0I suspect the DVI port is using UNIPHY A o= r A+B > >> > > (for dual link) and HDMI is using UNIPHY link B. =A0It's probably > >> > > actually using router objects (gpio toggle to switch gpio routing > >> > > between physical ports), however support for that is not implement= ed > >> > > yet which is why we have the current code. =A0Can you send me a co= py of > >> > > your vbios so I can verify? > >> > > > >> > > To access your vbios (as root): > >> > > cd /sys/bus/pci/device/ > >> > > echo 1 > rom > >> > > cat rom > /tmp/vbios.rom > >> > > echo 0 > rom > >> > > >> > Does the attached patch fix the issue? > >> > > >> > >> Thanks for the patch. I'll try it when I'm back where the dock is.. wi= ll take a couple of days. > >> > > > > Sorry it took a while.. I tried your patch now. > > It seems to fix the problem! > > > > When you send it upstream please also CC it for 2.6.33/2.6.34 stable br= anches? > > Just hoping to get the fix into Fedora 13.. > > > = > I've sent the patch to Dave and cc'ed stable. > = Great, thanks! -- Pasi > Alex > = > > -- Pasi > > > >> > >> > >> > From 557b452536c9390105539a264d342d963d71b087 Mon Sep 17 00:00:00 20= 01 > >> > From: Alex Deucher > >> > Date: Mon, 21 Jun 2010 12:07:52 -0400 > >> > Subject: [PATCH] drm/radeon/kms: fix shared ddc handling > >> > MIME-Version: 1.0 > >> > Content-Type: text/plain; charset=3DUTF-8 > >> > Content-Transfer-Encoding: 8bit > >> > > >> > Connectors with a shared ddc line can be connected to different > >> > encoders. > >> > > >> > Reported by Pasi K=E4rkk=E4inen on dri-devel > >> > > >> > Signed-off-by: Alex Deucher > >> > --- > >> > =A0drivers/gpu/drm/radeon/radeon_connectors.c | =A0 =A04 +++- > >> > =A01 files changed, 3 insertions(+), 1 deletions(-) > >> > > >> > diff --git a/drivers/gpu/drm/radeon/radeon_connectors.c b/drivers/gp= u/drm/radeon/radeon_connectors.c > >> > index 0c7ccc6..f58f8bd 100644 > >> > --- a/drivers/gpu/drm/radeon/radeon_connectors.c > >> > +++ b/drivers/gpu/drm/radeon/radeon_connectors.c > >> > @@ -785,7 +785,9 @@ static enum drm_connector_status radeon_dvi_dete= ct(struct drm_connector *connect > >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 if (connector =3D=3D list_connector) > >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 continue; > >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 list_radeon_connector =3D to_radeon_connector(list_connector); > >> > - =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 if (radeon_connector->devices =3D=3D list_radeon_connector->devices) { > >> > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 if (list_radeon_connector->shared_ddc && > >> > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 (list_radeon_connector->ddc_bus->rec.i2c_id =3D=3D > >> > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0radeon_connector->ddc_bus->rec.i2c_id)) { > >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 if (drm_detect_hdmi_monitor(radeon_connector->edid)) { > >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 if (connector->connector_type =3D=3D DR= M_MODE_CONNECTOR_DVID) { > >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 kfree(radeon_connector-= >edid); > >> > -- > >> > 1.7.0.1 > >> > > >> > >