NVidia nouveau video driver

From WikiHugovil

Jump to: navigation, search

I tried to follow the instructions on the official Nouveau wiki, but they confused me more than they helped me.

After a lot of trial and error and googling, I have successfully configured Nouveau on my system.

My system runs my own Linux distribution, HVLinux, based on LFS (Linux From Scratch).

Contents

Kernel

High-resolution console

I have found that in order for the Nouveau driver to work, you must first configure your kernel correctly and make sure it works in the command line environment (runlevel 3, no X.org server running).

Kernel source

I tried the official kernel linux-2.6.37.1 without success.

The git kernel from the Nouveau driver worked for me:

 $> git clone --depth 1 git://anongit.freedesktop.org/nouveau/linux-2.6

The option "--depth 1" fetches the current version without history.

Alternatively, you can use an archive of the nouveau kernel that I created from the GIT repository:

 http://www.hugovil.com/repository/hvlinux/packages/linux-2.6.38-rc7-g3d3d123-nouveau-git.tar.bz2

Kernel configuration

It seems that when I try to compile all the related drivers as modules, my system is booting fine (altough in a low resolution console), but when the udev daemon starts, my screen flickers, goes dark, and my system is frozen.

On the other hand, if I compile all the relevant drivers with the option "built-in" ([*] as opposed to [m]), my kernel boots in a high-resolution console, and the boot process completes correctlty.

 Device Drivers  --->
   Character devices  --->
     [*]   Support for binding and unbinding console drivers


Enable the "Direct Rendering Manager" option, but do not select anything UNDER the "Direct Rendering Manager" menu:

 Device Drivers  --->
   Graphics support  --->
     <*> Direct Rendering Manager (XFree86 4.1.0 and higher DRI support)  --->

Unselect everything in the "Support for frame buffer devices" menu:

 Device Drivers  --->
   Graphics support  --->
     < > Support for frame buffer devices --->

Finally select the Nouveau DRM driver:

 Device Drivers  --->
   Staging drivers  --->
     <*>  Nouveau (nVidia) cards
     [*]    Support for backlight control

After that, recompile your kernel and make sure your are able to boot with the high-resolution console.

libdrm

In the BLFS (Beyond Linux From Scratch) instructions for installing X.org, I replaced the stable libdrm-2.4.23 version with the git version:

 $> git clone git://anongit.freedesktop.org/git/mesa/drm libdrm-git
 $> cd libdrm-git
 $> ./autogen.sh
 $> ./configure --prefix=/usr --sysconfdir=/etc --enable-nouveau-experimental-api
 $> make
 $> make install

Alternatively, you can use an archive of libdrm that I created from the GIT repository:

 http://www.hugovil.com/repository/hvlinux/packages/libdrm-git-20110306.tar.bz2

MesaLib

In the BLFS (Beyond Linux From Scratch) instructions for installing X.org, I replaced MesaLib-7.9 with MesaLib-7.10.1, but by applying this patch:

 http://www.hugovil.com/repository/hvlinux/patches/MesaLib-7.10.1-nouveau-pushbuf.patch

xf86-video-nouveau

Get the Nouveau x.org driver from the git repository:

$> git clone git://anongit.freedesktop.org/git/nouveau/xf86-video-nouveau xf86-video-nouveau-git
 $> cd xf86-video-nouveau-git
 $> ./autogen.sh
 $> ./configure --prefix=/usr --sysconfdir=/etc
 $> make
 $> make install

Alternatively, you can use an archive of xf86-video-nouveau that I created from the GIT repository:

 http://www.hugovil.com/repository/hvlinux/packages/xf86-video-nouveau-git-20110306.tar.bz2

xorg.conf

Just typing startx won't work, because the nouveau driver will not be used by default.

Create a minimal /etc/X11/xorg.conf configuration file:

 Section "Device"
 Identifier "n"
 Driver "nouveau"
 EndSection

In the end

Now try startx and I you should have a working X environment using the Nouveau driver.


I must say a big thank-you to everyone who helped develop that open-source Nouveau driver.


But the next time I buy a computer, I will be more careful and stay far away from anything that has the nVidia name attached to it.


Shame on you nVidia for not providing open-source drivers!

Personal tools