PDA

View Full Version : Problem after compilation, during insmod


Pillyyy_Gott
12-10-02, 05:07 AM
Hello,

ok, ok, I know... It's the old Unresolved Symbols problem, you heard so often...

After downloading the drivers (the tar.gz packages), and successfully compiling them, the problem I have is that NVdriver does not pass module dependencies on my system currently.

I run a Suse Linux 6.3 System with a Nvidia TNT2 M64 Graphics Card. Here is the error message I am receiving for NVdriver (GLX seems to install fine):



quote:
--------------------------------------------------------------------------------

depmod: *** Unresolved symbols in /lib/modules/2.2.13/video/NVdriver

/lib/modules/2.2.13/video/NVdriver: unresolved symbol __global_cli

/lib/modules/2.2.13/video/NVdriver: unresolved tqueue_lock

/lib/modules/2.2.13/video/NVdriver: unresolved symbol __global_save_flags

/lib/modules/2.2.13/video/NVdriver: unresolved symbol __global_restore_flags

--------------------------------------------------------------------------------


I browsed all the threads in this forum and found, that a difference between running Kernel and the Link to the Header files is the reason for this behaviour.


So I checked my system and couldn't find any problems:

1. "uname -r" returns Kernel-Version 2.2.13
2. "/usr/include/linux" links to the right directory "/usr/src/linux/include/2.2.13"

So this could not be the problem, could it ?


Has anyone a solution for this?



Thank you in advance

Remo Pillat

beejay
12-10-02, 05:32 AM
Maybe you should upgrade your Kernel to linux-2.4.x (since the latest Kernel-Version is 2.4.20, you should use this one). It seems that NVDriver.o is linked against a feature not available in your kernel, so you should try the update.

bwkaz
12-10-02, 07:51 AM
I believe that the drivers do not require kernel 2.4. In any case, upgrading to 2.4 requires a ton of extra work (upgrading glibc, upgrading the compiler sometimes, etc.) that probably isn't worth it if you can get 2.2 to work just fine.

The link of /usr/include/linux to /usr/src/linux/include/2.2.13 could actually be the problem, if the headers in that directory are not configured properly. You really need to have it compile against the headers in a full kernel-source directory (except on Debian, I think -- I've heard that it works with just kernel-headers-<version>, but I've never seen for myself -- for anything else, you will need a full kernel-source).

The fact that there's a version number directory under /usr/src/linux/include/ makes me think that for some reason, SuSE 6.3 puts multiple kernel include directories under /usr/src/linux/include, which is pretty much wrong...

Is there a /lib/modules/2.2.13/build symlink? If so, where does it point to?

If not (or if it's a broken link), then if you grab a tarball of 2.2.13 (or a SuSE package), extract it to somewhere (doesn't matter where, really), find the config file that SuSE used to compile that kernel and copy it to the root of the new kernel source directory (name it .config), and then finally run make mrproper oldconfig dep, that should give you a properly-configured kernel source directory. Then, all you have to do is recreate the /lib/modules/2.2.13/build symlink -- point it at the root of wherever you put the kernel source.

For example, if I unpack linux-2.2.13 into my home directory, I'd have a ~/linux directory created. Personally, I'd rename that directory to ~/linux-2.2.13, but that's not strictly necessary. I'd then find the proper config file and copy it into there under the name .config, then cd into there and run that make stuff. Then I'd do (as root) an ln -s /home/bilbo/linux-2.2.13 /lib/modules/2.2.13/build to recreate the symlink. Then, go to the NVIDIA_kernel directory and make clean, followed by another make or make install.

Pillyyy_Gott
12-12-02, 01:09 AM
I'm sorry, but I was very busy the last days, so that I couldn't answer yet...

So this morning I followed your instructions. And there was no build Symlink. My next steps:

1. Download Kernel-Source 2.2.13 from www.kernel.org
and unpacked it to /home/Linux-2.2.13

2. copy /usr/src/linux-2.2.13/arch/i386/defconfig to /home/Linux- 2.2.13/.config


4. reinstantiated a symlink with ln -s /home/Linux-2.2.13 /lib/modules/2.2.13/build

5. did a make clean followed by a make in the Linux - Kernel directory


Nevertheless, the output was the same; the same unresolved symbols like before.
It's horrifying!!

Maybe you have another proposal?


Thanks for your assistance

bwkaz
12-12-02, 07:54 AM
Any chance of upgrading to a more recent SuSE? It'd be worth a shot, at any rate...

The other thing is, when you copied the .config file, did you run make mrproper oldconfig dep from inside your /home/Linux-2.2.13 directory? If not, try it and restart with the NVIDIA_kernel.

Also, when you do a make in the NVIDIA_kernel directory, take note of which include directory the driver is using -- or just post (or attach) what it prints while it's compiling, that would work as well.

Pillyyy_Gott
12-13-02, 04:04 AM
Problem is solved !!!

The Kernel has to be configured for Single-Processor-Usage, that means the SMP feature has to be disabled.

So I did a make mrproper oldconfig menuconfig dep and disabled in Processor Settings the Option SMP.

Then the Linking - process was no problem and no unresolved symbols appeared.

Thank you all for your help