# Why no nVidia-Driver active?

## tkhobbes

Hi all

I just did, out of curiosity mainly, a cat /proc/driver/nvidia/agp/status - here's the result:

```
Status:          Disabled
```

Funny - I emerged the nvidia-kernel package, and my /etc/modules.autoload.d/kernel-2.6 contains a line saying

```
nvidia
```

A dmesg gives those lines (of which I think they might be of interest:

```

Linux agpgart interface v0.100 (c) Dave Jones

vesafb: NVidia Corporation, NV25 Board, Chip Rev    (OEM: NVidia)

vesafb: VBE version: 3.0

vesafb: protected mode interface info at c000:ea90

vesafb: pmi: set display start = c00cead5, set palette = c00ceb5a

vesafb: pmi: ports = b4c3 b503 ba03 c003 c103 c403 c503 c603 c703 c803 c903 cc03 ce03 cf03 d003 d103 d203 d303 d403 d503 da03 ff03

vesafb: hardware supports DCC2 transfers

vesafb: monitor limits: vf = 85 Hz, hf = 68 kHz, clk = 108 MHz

vesafb: scrolling: redraw

Console: switching to colour frame buffer device 128x48

vesafb: framebuffer at 0xf0000000, mapped to 0xf8880000, size 16384k

fb0: VESA VGA frame buffer device

vga16fb: initializing

vga16fb: mapped to 0xc00a0000

fb1: VGA16 VGA frame buffer device

```

and later

```
nvidia: module license 'NVIDIA' taints kernel.
```

and again later

```
NVRM: loading NVIDIA Linux x86 NVIDIA Kernel Module  1.0-6111  Tue Jul 27 07:55:38 PDT 2004
```

What do I need to do in order that the first result is not "disabled" but "enabled"? What's wrong?

thank you

thomas

----------

## dkaplowitz

Interesting. I get the same output from /proc/driver/nvida/agp/status. I'm not really missing much by way of graphical performance, I think my glxgears performance is in the 7000FPS average range. I'm pushing 1600 res and get the nVidia splash screen, so the driver's working. I wonder if I'm missing something.

----------

## NeddySeagoon

tkhobbes,

Your 

```
cat /proc/driver/nvidia/agp/status
```

means that you are not making use of the nVidia AGP driver witch is only a part of the nVidia provide module. The driver itsself is still present and correct.

To use the nVidia AGP driver you must remove all other AGP drivers from the kernel, since the nVidia one cannot load is another AGP driver is alrey loaded.

The nVidia module loads by default if it can. You can apply gentle pressure with

```
  Option "NvAGP" "3"

# Configure AGP support. Integer argument can be one of:

#   0 : disable agp

#   1 : use NVIDIA's internal AGP support, if possible

#   2 : use AGPGART, if possible

#   3 : use any agp support (try AGPGART, then NVIDIA's AGP)

#       Please note that NVIDIA's internal AGP support cannot

#       work if AGPGART is either statically compiled into your

#       kernel or is built as a module, but loaded into your

#       kernel (some distributions load AGPGART into the kernel

#       at boot up).  Default: 3 (the default was 1 until after

#       1.0-1251).
```

in your xorg.conf Device section.

----------

## mike4148

 *Quote:*   

> means that you are not making use of the nVidia AGP driver witch is only a part of the nVidia provide module.

 

That's not correct. It will give you good output, even if you are using agpgart (like me). One thing to note: it always says "Disabled" when your X server is not running, even if the driver is loaded.

If there's an actual problem with AGP, it will show up in your X log (/var/log/XFree86.0.log or /var/log/xorg.0.log).

----------

## emes

tkhobbes: I assume you set the driver in the X configuration file?

----------

## tkhobbes

Hi there

Thanks for those answers.

The point is, that I have VERY bad performance for example with tuxracer or tuxcart - and I want to solve this.  :Smile: 

glxgears give me some output like this:

```

1236 frames in 5.0 seconds = 247.200 FPS

1360 frames in 5.0 seconds = 272.000 FPS

1475 frames in 5.0 seconds = 295.000 FPS

1249 frames in 5.0 seconds = 249.800 FPS

3064 frames in 5.0 seconds = 612.800 FPS

2838 frames in 5.0 seconds = 567.600 FPS

2610 frames in 5.0 seconds = 522.000 FPS

1362 frames in 5.0 seconds = 272.400 FPS

2951 frames in 5.0 seconds = 590.200 FPS

3178 frames in 5.0 seconds = 635.600 FPS

```

...which I think is VERY bad...

Here some answers to your questions:

 *Quote:*   

> and get the nVidia splash screen

 

...well, I don't get any nVidia splash screen - I think it sould show up when I start X?

NeddySeagon: Your suggestion sounds interesting - in which section do I put this option?

And finally - I tried to set the driver in X according to the "Gentoo Linux nVidia Guide" - but it did not work - as soon as I changed the driver from the original "nv" to "nvidia", X would not start up any more (the screen remains black and I had to do a reset - no evidences in Xorg.0.log about any error)...

thomas

----------

## NeddySeagoon

tkhobbes,

With glxgears time like that, I wonder if you are actually using the the nVidia driver.

Here is a fragment of my xorg.conf file

```
########################################################################

# Section Added by NeddySeagoon For nVidia based Graphics Card

# The options are copired from the README file

# They don't all apply to all Graphics Chips

Section "Device"

    Identifier  "NVIDIA GeForce"

#    Driver     "nv"

    Driver      "nvidia"

#    VideoRam   131072

#    Insert Clocks lines here if appropriate

# The following driver options are supported by the NVIDIA XFree86 driver:

 Option "NvAGP" "3"

# Configure AGP support. Integer argument can be one of:

#   0 : disable agp

#   1 : use NVIDIA's internal AGP support, if possible

#   2 : use AGPGART, if possible

#   3 : use any agp support (try AGPGART, then NVIDIA's AGP)

#       Please note that NVIDIA's internal AGP support cannot

#       work if AGPGART is either statically compiled into your

#       kernel or is built as a module, but loaded into your

#       kernel (some distributions load AGPGART into the kernel

#       at boot up).  Default: 3 (the default was 1 until after

#       1.0-1251).

# Option "NoLogo" "boolean"

#         Disable drawing of the NVIDIA logo splash screen at

#         X startup.  Default: the logo is drawn.

 Option "RenderAccel" "1"

```

Note the commented out nv driver and the use of nvidia.

I've also shown the AGP option settings and  Option "RenderAccel" "1" which is supposed to be A Good Thing(tm)

----------

## tkhobbes

NeddySeagoon: Thanks but as I said, when I use the "nvidia" driver instead of "nv", X won't start any more.  :Sad: 

I really don't know what to do - because I *do* have a nvidia-card...  :Smile: 

----------

## NeddySeagoon

tkhobbes,

Please post the the output of

```
lspci 
```

related to to Video card, the output of 

```
uname -a
```

 so that I can see your running kernel, the output of 

```
emerge nvidia-kernel nvidia-glx  -p
```

 to show what nvidia modules are installed and confirm that a module called nvidia appears in 

```
lsmod
```

That will do me to be going on with.

----------

## tkhobbes

NeddySeagoon,

Sorry for not replying for such a long time - I have been very busy lately...  :Sad: 

Anyway, here you go:

Output of lspci:

```
0000:01:00.0 VGA compatible controller: nVidia Corporation NV25 [GeForce4 Ti 4200] (rev a2)

```

Of uname -a:

```
Linux tangoling 2.6.9-gentoo-r1 #5 Mon Nov 29 15:08:19 CET 2004 i686 Intel(R) Pentium(R) 4 CPU 2.53GHz GenuineIntel GNU/Linux

```

of the emerge-command:

```
[ebuild   R   ] media-video/nvidia-kernel-1.0.6111-r3

[ebuild   R   ] media-video/nvidia-glx-1.0.6111

```

and finally of lsmod:

```
nvidia               4812660  -

```

Thanks in advance for your help...  :Smile: 

thomas

----------

## NeddySeagoon

tkhobbes,

I've been away all week - unexpectedly.

That all looks good.

Set up xorg.conf to use the nvidia driver. Post the xorg.conf file and the /var/log/Xorg.0.log that is generated from the failed startup. /var/log/Xorg.0.log is written every time X starts, so you need to save it from the terminal. before you umake X work again to post.

The log is quite big, so if you have some webspace, put both files there amd post links.

----------

## tkhobbes

NeddySeagoon

Funny - I posted yesterday, but somehow my post disappeared - maybe I had a timeout while posting...

Anyway - here's my xorg.conf:

http://www.rafb.net/paste/results/do1BWZ79.html

And here's the corresponding Xorg.0.log:

http://www.rafb.net/paste/results/g5P3GI68.html

When I start X, the screen turns black - and I can't use a CTRL-ALT-F1 to go back to my first console or so - I have to do a hard reset...  :Sad: 

thomas

----------

## NeddySeagoon

tkhobbes,

Your xorg.conf looks good and there are no errors in your log, its just truncated. I have a similar set up to you, graphics card wise.

To make your xorg,conf work here, all I had to do was remove the 

```
BusID       "PCI:1:0:0"
```

statement, since my AGP is not PCI bus 1.

Try removeing the lines 

```
   VendorName  "nVidia Corporation"

   BoardName   "NV25 [GeForce4 Ti 4200]"

   BusID       "PCI:1:0:0"

   Option "NvAGP" "3"

   Option "RenderAccel" "1"
```

which are all optional anyway.

That will get you a minimal Device section. Post the updated xorg.conf and log file.

----------

## tkhobbes

NeddySeagoon

It did not work. I commented out everything as you suggested, but still have the same error...  :Sad: 

The Xorg.0.log file looks the same (truncated)

...and I thought that this would solve the problem...

 :Sad: 

thomas

----------

## NeddySeagoon

tkhobbes,

One last straw to grasp. Run  

```
opengl-update nvidia
```

to make sure you have the right opengl version selected.

----------

## mike4148

First, try setting NvAGP to "0." This will disable AGP. Many bizarre lockups are AGP-related.

If that doesn't work, and your card has multiple non-TV outputs (like mine, two DVI + one S-Video), try plugging your monitor into the other output. The card may have a conflicting idea of which output is the "primary."

----------

## tkhobbes

Hi there

OK, I did the following: I changed the line NvAGP to "0" and did a "opengl-update nvidia" - now X will start, even with the driver "nvidia". However, the startup of X seems to take a little bit longer...

Now, glxgears gives me this output:

```
10208 frames in 5.0 seconds = 2041.600 FPS

12700 frames in 5.0 seconds = 2540.000 FPS

13001 frames in 5.0 seconds = 2600.200 FPS

12313 frames in 5.0 seconds = 2462.600 FPS

13380 frames in 5.0 seconds = 2676.000 FPS

13440 frames in 5.0 seconds = 2688.000 FPS

13408 frames in 5.0 seconds = 2681.600 FPS

13449 frames in 5.0 seconds = 2689.800 FPS

13428 frames in 5.0 seconds = 2685.600 FPS

13410 frames in 5.0 seconds = 2682.000 FPS

13435 frames in 5.0 seconds = 2687.000 FPS

13442 frames in 5.0 seconds = 2688.400 FPS

13437 frames in 5.0 seconds = 2687.400 FPS

13257 frames in 5.0 seconds = 2651.400 FPS

```

...how is that?

thomas

----------

## NeddySeagoon

tkhobbes,

You have turned off the AGP driver, now nVidia works. I get

```
26927 frames in 5.0 seconds = 5385.400 FPS

29615 frames in 5.0 seconds = 5923.000 FPS

29703 frames in 5.0 seconds = 5940.600 FPS

29104 frames in 5.0 seconds = 5820.800 FPS
```

with a 4200 based graphics card and without fast writes enabled.

What AGP driver do you have built into your kernel, if any?

That will prevent the nVidia AGP driver being used.

Post a fragment of your /usr/src/linux/.config file shwoing the AGP set up.

----------

## tkhobbes

Here you go (I could not find these options in the menu-based make thingies, but here they are):

```
CONFIG_AGP=y

# CONFIG_AGP_ALI is not set

# CONFIG_AGP_ATI is not set

# CONFIG_AGP_AMD is not set

# CONFIG_AGP_AMD64 is not set

# CONFIG_AGP_INTEL is not set

# CONFIG_AGP_INTEL_MCH is not set

CONFIG_AGP_NVIDIA=y

# CONFIG_AGP_SIS is not set

# CONFIG_AGP_SWORKS is not set

# CONFIG_AGP_VIA is not set

# CONFIG_AGP_EFFICEON is not set

```

thomas

----------

## NeddySeagoon

tkhobbes,

The setting 

```
CONFIG_AGP_NVIDIA=y 
```

builds the kernels  nVidia AGP driver into the kernel, which prevents the one supplied with the nVidia graphics driver from being used. You need to rebuild the kernel with that option off, then use the nVidia AGP option in xorg.conf..

================= edit ======================

This is the AGP driver for your chipset on the motherboard, not your graphics card.

----------

## tkhobbes

I turned the whole agp-section (agpart) off (I finally found it in the menus...) - but I have still the same error; when using NvAGP "3" X won't start.

However, I discovered that I once added the module nvidia to my /etc/modules.autoload.d/kernel-2.6 file (and it gets loaded); that's the only thing I can now think of that could interfere...

Or could it?

thomas

----------

## NeddySeagoon

tkhobbes,

The nVidia kernel module is essential to runnig the nVidia graphics driver. Its beginning to sound like the nVidia AGP driver (a small part of the package) does not set up your AGP chip set properly.

What motherboard do you have?

----------

## tkhobbes

Hi

I think that my hardware is ok - I have a dual-boot with windows xp, and the windows drivers do work.

I have an ASUS P4PE motherboard and an ASUS V8420 graphic card...

thomas

----------

