# nvidia module (error... no such device)

## Redge

Hi,

I'm having a problem with the nvidia driver since the beginning of my gentoo install (~2 weeks). I'm stuck with this error when i try to do a modprobe nvidia:

```
FATAL: Error inserting nvidia (/lib/modules/2.6.18-gentoo-r2/video/nvidia.ko): No such device

```

I try to solve this problem in different way:

 :Arrow:  doing an  emerge -eav system and emerge -eav world and recompiling my kernel

 :Arrow:  emerging hotplug

 :Arrow:  trying the nvidia-legacy-drivers while my graphic card is supposed to support the new one (GeForce4 MX)

 :Arrow:  adding this script [url]

https://forums.gentoo.org/viewtopic-t-414259-highlight-devfsd.html[/url] because ls -l /dev/nvidia* gives nothing.

 :Arrow:  compiling my kernel in different ways

 :Arrow:  ...

ls -l /usr/src/linux and uname -a are the same, no framebuffer are activated in my kernel configuration, only the vesafb which allow me to try to solve my problem with the gentoo forum. /dev/agpart is set, loadable module support is set. lspci gives:

```
lspci | grep nVidia

00:00.0 Host bridge: nVidia Corporation nForce2 AGP (different version?) (rev a2)

00:00.1 RAM memory: nVidia Corporation nForce2 Memory Controller 1 (rev a2)

00:00.2 RAM memory: nVidia Corporation nForce2 Memory Controller 4 (rev a2)

00:00.3 RAM memory: nVidia Corporation nForce2 Memory Controller 3 (rev a2)

00:00.4 RAM memory: nVidia Corporation nForce2 Memory Controller 2 (rev a2)

00:00.5 RAM memory: nVidia Corporation nForce2 Memory Controller 5 (rev a2)

00:01.0 ISA bridge: nVidia Corporation nForce2 ISA Bridge (rev a3)

00:01.1 SMBus: nVidia Corporation nForce2 SMBus (MCP) (rev a2)

00:02.0 USB Controller: nVidia Corporation nForce2 USB Controller (rev a3)

00:02.1 USB Controller: nVidia Corporation nForce2 USB Controller (rev a3)

00:02.2 USB Controller: nVidia Corporation nForce2 USB Controller (rev a3)

00:04.0 Ethernet controller: nVidia Corporation nForce2 Ethernet Controller (rev a1)

00:05.0 Multimedia audio controller: nVidia Corporation nForce Audio Processing Unit (rev a2)

00:06.0 Multimedia audio controller: nVidia Corporation nForce2 AC97 Audio Controler (MCP) (rev a1)

00:08.0 PCI bridge: nVidia Corporation nForce2 External PCI Bridge (rev a3)

00:09.0 IDE interface: nVidia Corporation nForce2 IDE (rev a2)

00:0d.0 FireWire (IEEE 1394): nVidia Corporation nForce2 FireWire (IEEE 1394) Controller (rev a3)

00:1e.0 PCI bridge: nVidia Corporation nForce2 AGP (rev a2)

02:00.0 VGA compatible controller: nVidia Corporation NV18 [GeForce4 MX - nForce GPU] (rev a3)
```

lots of nvidia things because i have a nforce2 chipset.

dmesg:

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

 which i don't really understand.

and my USE variable in my make.conf:

```
USE="3dnow 3dnowext sse mmx mmxext quicktime real win32codecs vcd vidix divx4linux encode X aac

acpi alsa cdr dvdr dvdread fftw ffmpeg firefox ftp gnome gstreamer gtk gtk2 imagemagick nvidia jpeg jpeg2k mplayer png -kde -qt3 -qt4 -arts -eds -esd userlocales"

VIDEO_CARDS="nvidia"
```

There must be something missing but i don't know what. Any solution? I would be very grateful!

----------

## erik258

 *Quote:*   

> recompiling my kernel 

 

a very good idea i think.  

 *Quote:*   

> emerging hotplug 

 

probably not related to nvidia

 *Quote:*   

> trying the nvidia-legacy-drivers while my graphic card is supposed to support the new one (GeForce4 MX) 

 

be on the lookout for the problems this causes. you may want to  search on forums.  

 *Quote:*   

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

 

the nvidia module is not open source.  nvidia develops it.  therefore it 'taints' an otherwise completely open kernel  anyway it's not your problem.

try running grep CONFIG_AGP_NVIDIA to see if you have support for your hardware: 

-> Device Drivers   -> Character devices  -> /dev/agpgart (AGP Support) (AGP [=y])

you also need apic or something, mtrr maybe; you want that stuff anyway of course.

----------

## Redge

```
 more .config | grep CONFIG_AGP_NVIDIA

CONFIG_AGP_NVIDIA=y

more .config | grep APIC

CONFIG_X86_GOOD_APIC=y

CONFIG_X86_UP_APIC=y

CONFIG_X86_UP_IOAPIC=y

CONFIG_X86_LOCAL_APIC=y

CONFIG_X86_IO_APIC=y

more .config | grep MTRR

CONFIG_MTRR=y

```

It seems like it's ok. I agree with you for the hotplug stuff, it's not probably related but i just followed the instruction here: https://forums.gentoo.org/viewtopic-t-501908-highlight-hotplug+nvidia.html

thanks for clarifying 'NVIDIA' taints kernel

----------

## zAfi

hey!

you need to remove CONFIG_AGP_NVIDIA=y (the kernel drivers conflict with the binary nvidia drivers). Use "ESA VGA graphics support" instead and select either vesafb or vesafb-tng. Then you need to add "/dev/agpgart (AGP Support)" to your kernel (You find it under "Device Drivers, Character Devices". Recompile your kernel and then reemerge nvidia-drivers. That should do the trick!

----------

## Dan

also keep in mind that as of the 9742 driver your card is no longer supported(even though the README says it is) so use 8776 or 9629

----------

## erik258

 *Quote:*   

> you need to remove CONFIG_AGP_NVIDIA=y

 

oh, i'm not so sure about that.  i have it in my kernel and it conflicts with nothing.  

just because you heed a binary driver for your nvidia GPU doesn't mean you don't still need the drivers for your motherboard's agp gart .

but thry the suggestion, for sure.  what do i know?  besides, it's only  in my kernel by mistake, as i am on an nforce 4 chipset and therefore use the onborard gart onmy amd64.  so that may change results for incompatablility.  nevertheless,  i am confident this won't solve your problem as i've set up x/nvidia on lots of boxes and never have this problem, and i always load support for the agp hardware per motherboard chipset / lspci output. 

 *Quote:*   

> also keep in mind that as of the 9742 driver your card is no longer supported(even though the README says it is) so use 8776 or 9629

 

really? are you sure?  

if so, that is probably a very, very helpful idea.  notice that you may not necessarily want the legacy drivers, though, justa specific nvidia driver release.  

dcoats, can you help me find more info on this?

----------

## Redge

Ok, thanks for your help. With or without CONFIG_AGP_NVIDIA set, i get the same error message at modprobe. And  i'm allready using the old version of the driver: 8776. This is what i see when i'm trying to emerge nvidia-drivers. 

How can i be sure about the version number?

 *Quote:*   

> just because you heed a binary driver for your nvidia GPU doesn't mean you don't still need the drivers for your motherboard's agp gart . 

 

This is exactely what i was wondering as I have a nforce2 chipset....   :Sad: 

----------

## downey

You don't need the motherboard specific AGP support, you only need the base AGP support.  NVidia uses it's own AGP system which communicates with the base AGPGART kernel system.  So anything after that is not needed if you use the nvidia driver.   If you switch to the nv driver then you most likely will need the other AGP support.  Normally you should build the AGP stuff as modules as the system will then use what it needs when it needs it.  Select them as "M" instead of as "Y" in the kernel setup.  Also check to see if you have any of the Direct Rendering Manager system set up in the kernel.  If you do then pull it all out as it also is not needed.

----------

## zAfi

downey is right! Well almost, but even if you only use nv you don't need the specific agp support as the os-nvidia driver works with agppart.

What came into my mind was that maybe you have the wrong kernel symlinks set?? I had a similar problem because I forgot to update the kernel symlink. Plz post the output of _uname -a_ and _ls -l /usr/src_

btw. when you recompile your kernel, how do you proceed? Have you ever tried to _make clean_ (backup your .config somewherebefore that) to get rid of the old modules before _make && make modules_install_???

----------

## Dan

 *Quote:*   

> dcoats, can you help me find more info on this?

 

well for starters If you have a Geforce4 then try it, it will not work...

even though the doc wasnt updated.. http://us.download.nvidia.com/XFree86/Linux-x86/1.0-9742/README/appendix-a.html

I have reported it already, They agree that the Doc needs to be updated and the Geforce4 is going to legacy  :Sad: 

From: Nvidia

Re: 9742 readme is wrong

Thanks for clarifying, you're correct the README needs to be updated. I've opened bug 266882 for that issue.

Thanks,

Lonni

----------

## erik258

how very interesting.  thanks all.  

 *Quote:*   

> well for starters If you have a Geforce4 then try it, it will not work... 

 

well it certainly looks like it.  

 *Quote:*   

> 
> 
> You don't need the motherboard specific AGP support, you only need the base AGP support.

 

i never should have doubted you ; )  the guide says it all.

----------

