LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 02-27-2003, 01:18 AM   #1
wr3ck3d
Member
 
Registered: Dec 2002
Location: IL
Distribution: NetBSD, Slackware, Gentoo, Debian, FreeBSD
Posts: 444

Rep: Reputation: 31
compile a single kernel module


i kinda already posted this in the slackware forum but not really getting any help so will jsut make it quick in here.....after i patch the kernel and do a make "menuconfig", how can i just compile a single module instead doing "make modules" and making them all?? the file is ppp_mppe.c and its in the /drivers/net folder of the kernel source. I looked in the makefile in there and the new module is listed in there just need to know how to make it -thanks
 
Old 02-27-2003, 02:08 AM   #2
xYko
Member
 
Registered: Feb 2003
Location: Helsingborg, Sweden
Distribution: Slackware
Posts: 52

Rep: Reputation: 16
No idea. But once you 'make modules', don't do a 'make clean'. That way if you configure in a new module and make modules, only it will get compiled. Works for me...
 
Old 02-27-2003, 02:41 AM   #3
wr3ck3d
Member
 
Registered: Dec 2002
Location: IL
Distribution: NetBSD, Slackware, Gentoo, Debian, FreeBSD
Posts: 444

Original Poster
Rep: Reputation: 31
lol, i am having deja vu, i just made all of them, then

cp /drivers/net/ppp_mppe.o /lib/modules/linux/drviers/net
depmod -a (have no clue what that does but always remember instructions say to do it, so just figured maybe needed to be done)
modprobe ppp_mppe----cant find it
modprobe ppp_mppe.o---cant find it
insmod ppp_mppe---unresoved symbol register compressor, unregister compresser

i am getting a unresolved symbol error and that is the same error i got when trying to manually put in a r128 module before. Also all the modules are in gzip format, this is just the .o (object i think its called) file. Hopefully i there is a way to do this without installing all of the modules. -thanks
 
Old 02-27-2003, 04:48 AM   #4
xYko
Member
 
Registered: Feb 2003
Location: Helsingborg, Sweden
Distribution: Slackware
Posts: 52

Rep: Reputation: 16
I'm no expert but that looks like you don't have the same version of the kernel as the module. I used to get that unresolved symbol error when I accidentally ran 2.4 modules with 2.2 kernel..

Not sure whether its actually *possible* to run a different version module than your kernel is, but it sure never worked for me
So if you patched the kernel and only made modules, that could be it.
 
Old 02-28-2003, 06:32 AM   #5
DaOne
Member
 
Registered: Jan 2003
Location: USA
Distribution: Slackware
Posts: 498

Rep: Reputation: 30
Quote:
Not sure whether its actually *possible* to run a different version module than your kernel is, but it sure never worked for me
I believe that there is something in the kernel that sets the version for the modules that allows you to run different version modules or 3rd party modules.

I believe that if you do all the things in order and don't skip anything you should be ok.

make menuconfig
make dep
make clean
make bzImage
make
make install (as long as you've properly edited lilo.conf and Makefile)
make modules
make modules_install

I think xYko is right...you need to do a make modules_install.
 
Old 02-28-2003, 08:22 AM   #6
wr3ck3d
Member
 
Registered: Dec 2002
Location: IL
Distribution: NetBSD, Slackware, Gentoo, Debian, FreeBSD
Posts: 444

Original Poster
Rep: Reputation: 31
ok, i did what you said DaOne and just installed all of the modules...now i am back to where was before with getting Direct Rendering to work.....here is the error in am getting when trying to install DRI.

make: `r128.o' is up to date.
/usr/X11R6/lib
/lib/modules/2.4.18/kernel/drivers/char/drm/r128.o: unresolved symbol cmpxchg
/lib/modules/2.4.18/kernel/drivers/char/drm/r128.o: insmod
/lib/modules/2.4.18/kernel/drivers/char/drm/r128.o failed
/lib/modules/2.4.18/kernel/drivers/char/drm/r128.o: insmod r128 failed

I am still using the 2.4.18 kernel, when i reinstalled all the moduels it does not include DRI this time.....its pretty obvious to me that this is the problem but just want a experienced person opinion..................... ..http://dri.sourceforge.net/faq/faq_display.phtml?id=18, seems like i am going to have to either download all of X again (at a internet cafe of course), or say screw mppc compression and just reinstall linux, or maybe there is a way to just reinstall X from the installation CD since that came DRI ready but without there being module difference problems...i know for sure the 2.4.19 kernels dont include dri so maybe the 2.4.20 does, anyone know?? -thanks

Last edited by wr3ck3d; 02-28-2003 at 08:27 AM.
 
Old 02-28-2003, 02:38 PM   #7
mesa
LQ Newbie
 
Registered: Feb 2003
Distribution: Slackware
Posts: 14

Rep: Reputation: 0
This is how i always setup dri-hardware accleration- 3d whatever you want to call it!

I disable dri/drm support in the kernel.

Then i either :

A) download dri-cvs and go through that entire process of upgrading my Xfree86 and use the modules it builds for the kernel. You just copy them from the dri source tree to /lib/modules/whatever whatever , then you run depmod -a.

OR

B) Download the binary module package from the DRI site and build my video drivers with that. Then copy the driver your needing to /lib/modules/<kernel-version>/whatever/path/

Either way never gives me a problem.

Make sure you kernel source is in /usr/src/linux before doing any of this.

mesa

Linux = Freedom
 
Old 02-28-2003, 04:43 PM   #8
UnTamed
Member
 
Registered: Dec 2002
Location: Qc, Canada
Distribution: CRUX
Posts: 317

Rep: Reputation: 30
>/lib/modules/2.4.18/kernel/drivers/char/drm/r128.o: unresolved symbol cmpxchg

Compile your kernel for i586 or better.
 
Old 02-28-2003, 08:34 PM   #9
wr3ck3d
Member
 
Registered: Dec 2002
Location: IL
Distribution: NetBSD, Slackware, Gentoo, Debian, FreeBSD
Posts: 444

Original Poster
Rep: Reputation: 31
Thanks Un Tamed.....when i compiled the 2.4.20 kernel i used the xconfig with help and realized i had left it at the 386 setting...got dri working also now , so everything seems ok. just hope i picked all the right settings in the xconfig.
 
Old 03-01-2003, 11:54 AM   #10
mesa
LQ Newbie
 
Registered: Feb 2003
Distribution: Slackware
Posts: 14

Rep: Reputation: 0
Im just curious as to which way you ahceived your dri.

I had posted a couple of exmples on how to do so ,which did you use ?

Did you compile dri-cvs or just get the modules-package from dri and insert those modules into the kernel ?

Just in case someone else reads and wants to know which direction you took !

Thanks,

mesa
Linux = Freedom
 
Old 03-01-2003, 12:00 PM   #11
wr3ck3d
Member
 
Registered: Dec 2002
Location: IL
Distribution: NetBSD, Slackware, Gentoo, Debian, FreeBSD
Posts: 444

Original Poster
Rep: Reputation: 31
I got the module package and ran ./install (something).....the problem was that when i recompiled the kernel i left it on 386 instead of changing to my pc.
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
How do you rebuild a single kernel module? rollo Linux - General 3 01-29-2006 01:19 AM
Compile in kernel or module? maginotjr Slackware 4 06-30-2005 11:54 AM
how to compile a single module? linjia Debian 1 12-26-2004 05:30 AM
Compile A Single Module leohuang Linux - General 4 05-02-2004 06:20 AM
can i compile just one kernel module whithout recompiling the whole kernel? edman007 Linux - Software 3 02-17-2004 03:05 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

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

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration