Make sure Nvidia drivers is used by agp

After install nvidia drivers I notice that agp driver status says I use agpgart not nvidia drivers.

pnix@pnix-a7n:~$ cat /proc/driver/nvidia/agp/status
Status: Enabled
AGP Rate: 8x
Fast Writes: Disabled
SBA: Enabled

even nvidia module is already loaded.
pnix@pnix-a7n:~$ lsmod|grep agpgart
agpgart 35400 2 nvidia,nvidia_agp

Some old tutorials will advice you try to disable agpgart[for 2.4 kernel] but not for 2.6.

From nvidia readme appendix F

"On Linux 2.6, the agpgart.ko frontend module will always be loaded, as it is used by the NVIDIA kernel module to determine if an AGPGART backend module is loaded. When the NVIDIA AGP driver is to be used on a Linux 2.6 system, it is recommended that you make sure the AGPGART backend drivers are built as modules and that they are not loaded."
this confirm by
pnix@pnix-a7n:~$ modinfo nvidia
filename: /lib/modules/2.6.20-16-generic/volatile/nvidia.ko
license: NVIDIA
alias: char-major-195-*
alias: pci:v000010DEd*sv*sd*bc03sc02i00*
alias: pci:v000010DEd*sv*sd*bc03sc00i00*
depends: agpgart,i2c-core
vermagic: 2.6.20-16-generic SMP mod_unload 586
parm: NVreg_VideoMemoryTypeOverride:int
parm: NVreg_RMEdgeIntrCheck:int
parm: nv_disable_pat:int

So anyways agpgart will be loaded because it's needed by nvidia drivers.
As I understand, There are two drivers nvidia_agp[the kernel module for NForce motherboards] and nvidia[proprietary drivers from nvidia]. If both are loaded together, nvidia_agp will be choosed and used as agp driver. To make sure nvidia drivers will be loaded, open /etc/modprobe.d/blacklist with your text editor, add "blacklist nvidia_agp"[for my case] to the end of file then reboot.
blacklist nvidia_agp

Check agp driver status again. Now it says NVIDIA
pnix@pnix-a7n:~$ cat /proc/driver/nvidia/agp/status
Status: Enabled
Driver: NVIDIA
AGP Rate: 8x
Fast Writes: Disabled
SBA: Enabled
pnix@pnix-a7n:~$ lsmod|grep agpgart
agpgart 35400 1 nvidia

Note: module to block is depend on output of lsmod|grep agpgart. It can be amd64_agp,sis_agp or something else.


Anonymous said...

i followed your method (added via_agp to blacklist), but when i went to check the driver, it said agp is disabled. i'm running ubuntu feisty 2.6.20-16-generic. i have a geforce 7300 gt vid card and 1gb of ram. any help is great. thx

pnix said...

what is output of your 'lsmod|grep agpgart' before you add blacklist.

Anonymous said...

agpgart 35400 2 nvidia,via_agp

Anonymous said...

oh yeah, i installed my nvidia drivers through envy, since i don't really know how to install it manually. i also had envy to autowrite my xorg.conf file. i appreciate your help

pnix said...

so, look like your nvidia module is loaded but may be it fail to initialize.

What's your "Device" section in '/etc/X11/xorg.conf'? and did you see anything wrong in your 'dmesg' output?

Anonymous said...

Here are links to my xorg.conf and dmesg. I don't think there's any errors mentioned in my dmesg, but then again I'm not quite sure how to read it? Anyways, here are the links... Thanks again for helping


pnix said...

wait, I'm confuse,
1. what is your 'cat /proc/driver/nvidia/agp/status' before and after adding via_agp to blacklist?
2. /var/log/Xorg.0.log before and after?

Anonymous said...

1. before i add via_agp to the blacklist, i have:
Status: Enabled
AGP Rate: 8x
Fast Writes: Disabled
SBA: Enabled

2. here is a link to the log file (before i add via_agp to the blacklist):

- again i'm not quite sure what i'm looking for, but i saw this "(II) NVIDIA(0): Using the NVIDIA 2D acceleration architecture". not sure if that means anything. but thanks for helping again.

Anonymous said...

this is what i get after adding via_agp to the blacklist:

1. Status: Disabled

AGP initialization failed, please check the ouput
of the 'dmesg' command and/or your system log file
for additional information on this problem.

2. this is the log:

3. this is the dmesg after adding via_agp to blacklist:


pnix said...

both your Xorg.0.log looked fine to me, nothing wrong with "(II) NVIDIA(0): Using the NVIDIA 2D acceleration architecture". nvidia driver is loaded correctly nothing error.
if 'cat /proc/driver/nvidia/agp/status' said "disabled", it should have some error show in dmesg or Xorg.0.log.

One more thing if you want to try is add 'Option "NvAGP" "1"' to your device section in /etc/X11/xorg.conf like this.

Section "Device"
Identifier "NVIDIA GeForce 7300 GT"
Driver "nvidia"
BusID "PCI:1:0:0"
VideoRam 512000
Option "NvAGP" "1"
Option "UseFBDev" "true"

Option "UseFastTLS" "3"


then reboot. If this kill your X or freeze your box reboot to recovery mode then take it out.

Anonymous said...

I added Option "NvAGP" "1" and still no luck. "cat /proc/driver/nvidia/agp/status" still brings up as disabled.

here is my log and dmesg.


i understand that there's probably not much more you can think of to help me out, but thanks again for trying. at least i got some feedback for once :)

pnix said...

I guess maybe this is specific for via chipset motherboard.

from README http://us.download.nvidia.com/XFree86/Linux-x86/100.14.11/README/chapter-12.html
the list of support via chipset are
VIA 8371
VIA 82C694X
VIA P4M266
VIA P4X400
VIA K8T800
VIA K8N800

what is youe mobo model and chipset?
let me guess again, if yours is not supported, nvidia recommend to use AGPGART that mean via-agp must be loaded. So your choice is remove via-agp from blacklist and use AGPGART until it support your chipset. find out more detail in the link.

and next time go for nforce :)


Anonymous said...

Oh, that's the problem. Yeah, I have a MSI PM8M-V mobo and it has the VIA P4M800 chipset. at least i know what the problem is now. thanks a lot :)