Lenovo T61 heads up: nvidia PowerMizer caution

Paul Johnson pauljohn32 at gmail.com
Sat Nov 22 18:22:37 UTC 2008


I'm trying to spread the word to people who like eye candy on laptops
with the Nvidia NVS140M video card.

I got a good deal on a new Lenovo T61 from the Lenovo outlet store
because Lenovo changed models. Many of my former-Dell using friends
recommended this model.   I was not interested in the newer Lenovo T
Series laptops because they feature the ATI video cards, rather than
the Nvidia.  I've avoided ATI for years because I had trouble with
them and generally I was able to make the Nvidia work with the
proprietary drivers.

Ubuntu 8.10 installed cleanly and almost everything worked with no
trouble.  Sound is fine.  The wireless is Intel iwl4965 and it works
very very well, much better than the iwl3945 in my Dell Latitude D820.
 The FN key combinations all work--suspend, network on/off. screen
light, and so forth.  The LCD display is WSXGA+, capable of 1680x1050,
and the Nvidia proprietary drivers version 177 delivers it just fine.
To my eye, that resolution is a bit "squished" and I prefer 1400x1050,
and had some trouble getting that display.  It turned out that the LCD
display returns an incorrect EDID frequency to the video card and so
some resolutions in linux seem impossible, although one can boot into
MS Windows and see that they really do work.  I could not get any
vertical and horizontal frequency information from Lenovo for the lcd,
so I had to guess with some settings in xorg.conf.  Eventually it did
work at 1400x1050.

But I've had trouble running some programs.  I use compiz as the
window manager/compositor because I like to have different wallpapers
on different workspaces.  Some programs that display text on the
screen simply don't "show" all text.  I posted a couple of examples of
mlterm where you can see black spots where the cursor or some file
lists should be:

http://pj.freefaculty.org/linux/mlterm-bad_ls-redraw.jpg
http://pj.freefaculty.org/linux/mlterm-nocursor.jpg

The blank spaces are filled in if you hit the return key a few times,
but it can be very inconvenient if you are paging through output with
"less" and the --less-- prompt is invisible at the bottom of the
terminal.  I use mlterm because it displays all international
characters and it allows me to set a background image from the command
line.  I have lots of background images and randomly choose them for
terminals.  I used to use Eterm, but it is still not quite ready to
display international characters.  I spent almost a whole day
compiling/ installing every terminal program I could find, never found
a good substitute.

Then I saw another malfunction in the display of LyX, my favorite
LaTeX document processor.  I would type in lines and then move the
cursor, and lines would be "drawn over" each other.  That made me
think i did not have an  mlterm problem, but rather a display problem.
 That led me to suspect the nvidia NVS140M video card was troubled,
and I started googling a lot.  I did  know know any magic words to
search for, and I've not found anybody who describes the exact same
problem.  But there are people in the Nvidia linux forum who describe
problems in Open Office.

One frustrating problem is that no two Nvidia cards seem to display
exactly the same trouble.  Some users describe problems like whole
terminals appear all black or that the display is corrupted by lots of
small geometric shapes.  Nvidia has umpteen different card models
placed in countless different motherboards with various displays.  I
found a lot of different fixups proposed, ranging from bits to add
into xorg.conf or kernel options.  For me, none of the xorg.conf
changes helped.  I learned that many of these don't apply on Ubuntu
8.10 because we are using the newer Xorg framework and a lot of the
advice you get for other linux systems is just outdated.

To make the rest of the long story shorter, it turns out this is the
fix for the T61.  An option for the nvidia kernel module can be used
to force the card's PowerMizer feature to stop slowing down the
display.  If this is not used, then the PowerMizer forces performance
setting to 0, which is so slow that the terminal does not completely
refresh itself.  If you force the performance level to 2, the display
is fine.  Here's what I have in the module settings:

$ cat /etc/modprobe.d/nvidia
options nvidia NVreg_RegistryDwords="PerfLevelSrc=0x2222"
options nvidia NVreg_Mobile=1

This uses more power; battery life is shorter by about 30minutes.  But
everything displays properly.

There is a lot of arguing about whose fault this is.  It does not
appear to happen if one uses Metacity in Gnome, it is inflicted only
on people who aim for accelerated 2d/3d effects.  Some gamers describe
this, but it mostly appears when one uses compiz or, as far as I can
tell, the KDE4 compositing window manager that is based on compiz
code.  Some people allege that the combination of Compiz and Nvidia
exposes a flaw in X11 that can be fixed, eventually.  Others in the
Nvidia list blame Nvidia for keeping their code closed.  Others blame
Compiz for, well, trying to use all the cool tools.  If I had a clear
idea of how this can be truly fixed, I'd file a bug report.  But I
expect the people who know how to fix this already know about it and
they are doing what they can to fix it.

There are also users in the Nvidia list saying they are giving up
entirely on Nvidia and switching to laptops with ATI cards.  I've not
tested this yet, but they say that ATI has a whole new open source
attitude and things are working much  better.  I don't know if I can
put much faith in that, and I still have a grudge from the crappy old
fglrx drivers that they used to peddle.  But, if I could replace the
Nvidia NVS140M with an ATI card in this laptop, I'd really like to try
it out.  And then I'll wish I had bought a new Lenovo T500, which does
have the ATI card with 256Meg.

-- 
Paul E. Johnson
Professor, Political Science
1541 Lilac Lane, Room 504
University of Kansas



Here's that xorg.conf file

Section "Monitor"
        Identifier      "Configured Monitor"
        HorizSync    24.0 - 100
        VertRefresh  30 - 90
        ModeLine     "1400x1050" 129.0 1400 1464 1656 1960 1050 1051
1054 1100 +hsync +vsync
        ModeLine     "1400x1050" 122.6 1400 1488 1640 1880 1050 1051
1054 1087 -hsync +vsync
        ModeLine     "1400x1050" 149.3 1400 1496 1648 1896 1050 1051
1054 1094 -hsync +vsync
        ModeLine     "1400x1050" 155.8 1400 1496 1648 1896 1050 1051
1054 1096 -hsync +vsync
        ModeLine     "1400x1050" 179.3 1400 1504 1656 1912 1050 1051
1054 1103 -hsync +vsync
        ModeLine     "1400x1050" 214.4 1400 1512 1664 1928 1050 1051
1054 1112 -hsync +vsync
        Modeline "1400x1050 at 60" 122.61 1400 1488 1640 1880 1050 1051
1054 1087 -hsync +vsync
        Modeline "1400x1050 at 75" 155.85 1400 1496 1648 1896 1050 1051
1054 1096 -hsync +vsync
EndSection

Section "Screen"
        Identifier      "Default Screen"
        Monitor         "Configured Monitor"
        Device          "Configured Video Device"
        Option      "ModeValidation" "NoEdidMaxPClkCheck"
        Option          "UseEdidFreqs" "False"
        DefaultDepth    24
        SubSection "Display"
                Viewport   0 0
                Depth     24
                Modes    "1400x1050" "1600x1050" "800x600" "640x480"
        EndSubSection
EndSection

Section "Module"
        Load    "glx"
EndSection

Section "Device"
        Identifier      "Configured Video Device"
        Option      "TwinView"
        Option      "MetaModes" "1400x1050,1280x1024"
        Option      "TwinViewOrientation" "Clone"
        Driver  "nvidia"
        Option  "NoLogo"        "True"
        Option "UseCompositeWrapper" "true"
EndSection




More information about the ubuntu-users mailing list