> Hi ! > I am new to rt-linux and also new to writing modules. > I first have installed mandrake 8.0 (kernel 2.4.3-20mdk) and thereafter i installed >kernel 2.4.4 and after that i installed rtlinux v3.1 (kernel 2.4.4-rtl). I can run >many of the examples from rt-linux without any problems what so ever. > I have written a very little and simple module under mandrake 8.0, which work fine >there. > I now wanted to try my module under rt-linux (even though i haven't used any of >rt-function-calls in rt-linux and the module isn't realtime). > I compile my sourcefile (ioex.c) whith "gcc -c ioex.c", then i want to load the >module with "insmod ioex.o" and then i get following "statement" : > > ioex.o: kernel-module version mismatch > ioex.o was compiled for kernel version 2.4.3-20mdk (my mandrake 8.0) > while this kernel is version 2.4.4-rtl > > I think that it must be gcc that is using some files from 2.4.3-20mdk, instead of >some from 2.4.4-rtl. > Can someone please help me with my problem (how to tell gcc to use the rigth files)? > I can load the module with "insmod -f ioex.o" but i would be glad to load it without >"forcing". > that happens when you have the link in /usr/include/linux pointing to the wrong kernel version - normaly
/usr/include/linux -> ../src/linux/include/linux /usr/include/asm -> ../src/linux/include/asm so you need to make shure that these links are corect AND that in /usr/src/ linux should be a link to the corect linux tree (make shure its not a directory) linux -> linux-2.4.4-rtl (or how ever you named the directory) cd linux and atleast run make menuconfig so that modversion.h is built. then go to the rtlinux-3.X/directory and ln -s /usr/src/linux linux (now rtlinux can find the corect kernel tree) make distclean make config make dep make now your modules should be for your 2.4.4-rtl kernel. hofrat -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED] -- For more information on Real-Time Linux see: http://www.rtlinux.org/
