Bug 17138

Summary: Randr12 on nv34m causes colour corruption on laptop panel.
Product: xorg Reporter: Murray Campbell <murray>
Component: Driver/nouveauAssignee: Nouveau Project <nouveau>
Status: RESOLVED FIXED QA Contact: Xorg Project Team <xorg-team>
Severity: normal    
Priority: medium    
Version: git   
Hardware: x86 (IA32)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Attachments:
Description Flags
vbtracetool vBIOS dump
none
Xorg.0.log without patch
none
Xorg.0.log with patch
none
(hopefully correct) fix none

Description Murray Campbell 2008-08-14 11:13:23 UTC
Created attachment 18284 [details]
vbtracetool vBIOS dump

Starting X with git nouveau and Randr12 disabled works perfectly.
Enabling Randr12 gives a somewhat corrupted screen which is predominantly red.

My system is a Dell Inspiron 5150 with a 1600x1200 screen and an nv34m.

The corruption is only on the internal panel. Any external screen on the VGA output seems to be fine.

Bug #14403 seemed to be the closest to my experience and so I messed around with nv_bios.c.

In the function parse_lvds_manufacturer_table_init the section labeled:

   /* adjust some things if straps are invalid (implies the panel has EDID) */

resets the lvdsmanufacturerindex from 3 to 0.

Putting in a line to set this back to 3 (or indeed 1 or 2) makes everything seem to work fine.

I did a BIOS dump with vbtracetool. Does this help?
Comment 1 Stuart Bennett 2008-08-14 11:32:41 UTC
Xorg.0.log while using randr12 as well please
Comment 2 Murray Campbell 2008-08-14 12:02:38 UTC
Created attachment 18285 [details]
Xorg.0.log without patch

This is the Xorg.0.log with Randr12 enabled and the original nv_bios.c
Comment 3 Murray Campbell 2008-08-14 12:06:08 UTC
Created attachment 18286 [details]
Xorg.0.log with patch

This is the Xorg.0.log with Randr12 enabled and nv_bios.c modified by applying the patch:

--- nv_bios.c   2008-08-14 19:56:33.000000000 +0100
+++ nv_bios.c.altered   2008-08-14 19:56:02.000000000 +0100
@@ -3154,6 +3154,8 @@
                         * lvdsmanufacturerindex in this case; we don't */
                }
 
+               lvdsmanufacturerindex=3;
+
                headerlen = 2;
                recordlen = bios->data[bios->fp.lvdsmanufacturerpointer + 1];
Comment 4 Stuart Bennett 2008-08-15 11:34:14 UTC
Created attachment 18301 [details] [review]
(hopefully correct) fix

Try this. There's a lot of code motion, so I might have got something wrong still.
Comment 5 Murray Campbell 2008-08-15 14:26:02 UTC
(In reply to comment #4)
 
> Try this. There's a lot of code motion, so I might have got something wrong
> still.

Well, it seems to work here. I'll let you know if anything unusual transpires.

There is a white thin-ish vertical line about half the screen high that flickers once as X starts. This never happened before but, of course, it's not a problem.

Thanks for looking into this so quickly.

Comment 6 Stuart Bennett 2008-08-15 16:33:19 UTC
Committed to master

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.