Go Back   nV News Forums > Linux Support Forums > NVIDIA Linux

Newegg Daily Deals

Reply
 
Thread Tools
Old 01-29-04, 01:04 AM   #1
gilboa
Linux addict...
 
Join Date: Jan 2004
Posts: 540
Default v2.6.0, 53.36, unable to map framebuffer. (Solved!)

Just installed the 53.36 drivers. Install went just fine. (--no-rpms option selected) modprobe nvidia works with both nvidia and agpgart loaded without a problem.
However, when I try to start X, it fails with an "Failed to map framebuffer memory" error. And in the kernel log I get two errors:
"0: NVRM: AGPGART: unable to retrieve symbol table"
"0: NVRM: couldn't find pre-allocated memory!"
(agp mmap fails?!?!?)

The machine worked just fine with the same kernel configuration using the minion.de patched 44.96 drivers.

Machine: Dual Athlon MP 2400, 1GB, SCSI RAID, GF5900/256MB.
OS: RedHat 9, Hand built 2.6.0 kernel (I'll upgrade to 2.6.1 later this week).

I've attached the XFree log file.
Attached Files
File Type: log xfree86.0.log (34.2 KB, 147 views)

Last edited by gilboa; 02-05-04 at 02:05 AM.
gilboa is offline   Reply With Quote
Old 01-29-04, 01:23 AM   #2
gilboa
Linux addict...
 
Join Date: Jan 2004
Posts: 540
Default

I should add that I must manually insmod the nvidia driver before starting the X. Unless I manually load the driver, X will fail on a "Failed to initialize the NVIDIA kernel modules" error. (I had the same error on v44.96.)

Cheers,
Gilboa

Last edited by gilboa; 01-29-04 at 02:45 AM.
gilboa is offline   Reply With Quote
Old 01-29-04, 02:47 AM   #3
gilboa
Linux addict...
 
Join Date: Jan 2004
Posts: 540
Default

2.6.1 produces the same problem. (Must load the nvidia driver by hand; NVRM fails to find pre-allocated memory.)

Tried Option NvAGP 1/2/3 in XF86Config. Neither worked.

Cheers,
Gilboa
gilboa is offline   Reply With Quote
Old 01-29-04, 09:44 AM   #4
gilboa
Linux addict...
 
Join Date: Jan 2004
Posts: 540
Default

OK. I checked the nVidia driver code and it seems that it failes to load symbols from the AGPGART.
I recompiled the AGPGART into the kernel... but still no go.

agpgart: Found an AGP 2.0 compliant device at 0000:00:00.0.
agpgart: Putting AGP V2 device at 0000:00:00.0 into 4x mode
agpgart: Putting AGP V2 device at 0000:01:05.0 into 4x mode
0: NVRM: couldn't find pre-allocated memory!


ARGH!!!!
gilboa is offline   Reply With Quote
Old 01-29-04, 03:15 PM   #5
Andy Mecham
l33t master
 
Join Date: Jul 2002
Location: Santa Clara, CA
Posts: 1,163
Default

I'm looking into this.

--andy
__________________
Andy Mecham
NVIDIA Corporation
Andy Mecham is offline   Reply With Quote
Old 01-30-04, 04:19 AM   #6
gilboa
Linux addict...
 
Join Date: Jan 2004
Posts: 540
Default

OK.

I've added a couple of printk's to the AMD 760 AGP and into the AGPGART.
As far as I can see, amd-k7-agp does call the agp_add_bridge, which in turn, calls the inter_module_register function. (which registers the drm_agp.)
The nvidia driver inter_module_get_request should not fail!!!

What the **** am I missing here?!?!? Argh!

More on that later...


EDIT: Found the source of one problem (after printk'ing it to death ): when I manually load the amd-k7-agp driver, the backend is being called and inter_module_get_request returns a valid pointer.
Now remains the second problem "couldn't find pre-allocated memory".

Looking into it now...

Edit 2: Things just got worse.
Uninstalled the drivers, tried reverting to the old configuration (2.6.0, 44.96/minion.de) and I'm getting the same problem.
I'm getting a new error before the "couldn't find pre-allocated memory" error.
NV: bad offset / length into frame buffer: 0x0 0xff00000 0x4000000.

Lesson to self, setup a second 2.6 machine to act as a guinea pig, before blowing the main production workstation

Last edited by gilboa; 01-30-04 at 11:15 AM.
gilboa is offline   Reply With Quote
Old 01-30-04, 02:32 PM   #7
gilboa
Linux addict...
 
Join Date: Jan 2004
Posts: 540
Default

Latest XFree86.0.log...
(Just in case...)
Attached Files
File Type: log xfree86.0.log (26.5 KB, 107 views)
gilboa is offline   Reply With Quote
Old 02-03-04, 01:36 AM   #8
gilboa
Linux addict...
 
Join Date: Jan 2004
Posts: 540
Default

OK.
I've compiled the drives with NVDEBUG=1 and this is the output.

[root@gilboa-home-dev gilboa]# cat /proc/mtrr
reg00: base=0x00000000 ( 0MB), size=1024MB: write-back, count=1
reg01: base=0xb8000000 (2944MB), size= 64MB: write-combining, count=1
[root@gilboa-home-dev gilboa]# dmesg -c
[root@gilboa-home-dev gilboa]# modprobe nvidia
[root@gilboa-home-dev gilboa]# X

XFree86 Version 4.3.0 (Red Hat Linux 9 release: 4.3.0-2.90.43)
Release Date: 15 August 2003
X Protocol Version 11, Revision 0, Release 6.6
Build Operating System: Linux 2.4.21-2.ELsmp i686 [ELF]
Build Date: 07 November 2003
Build Host: porky.devel.redhat.com
....
Module Loader present
OS Kernel: Linux version 2.6.1 (root@gilboa-home-dev) (gcc version 3.2.2 2003022
2 (Red Hat Linux 3.2.2-5)) #2 SMP Fri Jan 30 19:43:20 IST 2004 P
Markers: (--) probed, (**) from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/XFree86.0.log", Time: Tue Feb 3 09:34:20 2004
(==) Using config file: "/etc/X11/XF86Config"
(EE) NVIDIA(0): Failed to map framebuffer memory
(EE) NVIDIA(0): *** Aborting ***

Fatal server error:
AddScreen/ScreenInit failed for driver 0
...

[root@gilboa-home-dev gilboa]# rmmod nvidia
[root@gilboa-home-dev gilboa]# dmesg -c
nvidia: module license 'NVIDIA' taints kernel.
1: nvidia: loading NVIDIA Linux x86 NVIDIA Kernel Module 1.0-5336 Wed Jan 14 1
8:29:26 PST 2004
agpgart: Found an AGP 2.0 compliant device at 0000:00:00.0.
agpgart: Putting AGP V2 device at 0000:00:00.0 into 4x mode
agpgart: Putting AGP V2 device at 0000:01:05.0 into 4x mode
0: NVRM: couldn't find pre-allocated memory!
1: memory allocations:
1: total amount allocated: 0x0
1: memory allocations:
1: total amount allocated: 0x0
1: memory allocations:
1: total amount allocated: 0x0
1: final mem usage: vm 0x0 km 0x0 fp 0x0
[root@gilboa-home-dev gilboa]#

OK.
This didn't enable all the trace messages... going into the code again.
gilboa is offline   Reply With Quote

Old 02-03-04, 03:03 AM   #9
zander
NVIDIA Corporation
 
zander's Avatar
 
Join Date: Aug 2002
Posts: 3,740
Default

The problem looks to be that the card misreports the amount of installed video memory: the second PCI base address register reads back 64MB, which is what the kernel side of the NVIDIA driver will be referring to. When the NVIDIA XFree86 driver module attempts to map 256MB, the range isn't recognized by IS_FB_OFFSET() in nv_kern_mmap(), since it exceeds the probed 64MB; this also leads to the couldn't find pre-allocated memory error message. You could try fiddling nvos_probe_devices() to report 256MB, assuming the card really does have that much video memory installed. You'd also want to correct the corresponding MTRR entry. In any case, you'll want to contact the card's vendor requesting that the problem be fixed.
zander is offline   Reply With Quote
Old 02-03-04, 07:24 AM   #10
gilboa
Linux addict...
 
Join Date: Jan 2004
Posts: 540
Default

First, thanks for the help!

Reading your commenct I decided to re-check the mtrr settings and found the following:
mtrr: your CPUs had inconsistent fixed MTRR settings
mtrr: probably your BIOS does not setup all CPUs.
mtrr: corrected configuration.


Will rewriting the mtrr settings using the /proc interface solve the problem?
$echo "reg01: base=0xb8000000 size=0x10000000 type=write-combining" > /proc/mtrr
(Hardcoding the driver to detect 256MB seems like a lousy idea...)

Cheers,
gilboa is offline   Reply With Quote
Old 02-03-04, 07:45 AM   #11
zander
NVIDIA Corporation
 
zander's Avatar
 
Join Date: Aug 2002
Posts: 3,740
Default

You'll need to delete the old MTRR entry first, the command should be echo "base=0xb8000000 size=0x10000000 type=write-combining" > /proc/mtrr and no, it won't solve the actual problem; you'll want to override the probed value.
zander is offline   Reply With Quote
Old 02-03-04, 07:58 AM   #12
gilboa
Linux addict...
 
Join Date: Jan 2004
Posts: 540
Default

Sadly enough I'm at work now and my damn work firewall blocks my SSH access to my home network (baaah!) so I can't access the said machine.

Aside from hard coding the probed values, how can change the probed video memory window size? Is it a video card BIOS problem?
(The card is an Albartron FX5900QV Turbo 256MB card and Albatron doesn't have any BIOS upgrade for it.)

Cheers,
gilboa is offline   Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 07:37 PM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.