When insmodding I get a "function not implemented" message
Hi!
I have built a module to load it on a UML instance running a different kernel from the one I'm running on the host host. I have built the module against the headers for the kernel I'm using on the guest but when I try to insmod the module (on the guest, of course), I get a "function not implemented" message. Can insmod be a little more verbose about the function that is not implemented? I tried running strace on the insmod but the error comes from init_module so not much more information is available: Code:
open("r5r.ko", O_RDONLY) = 3 Code:
$ nm r5r.ko | while read a b c; do if [ "$c" == "" ]; then simbolo=$b; else simbolo=$c; fi; lineas=$( grep $simbolo simbolos.txt | wc -l ); if [ $lineas == 0 ]; then echo Symbol $simbolo is not defined; fi; done |
Don't you get an option, while compiling the kernel, named "Enable loadable module support"?
|
Anisha, thanks for your feedback.
Well, well.... very interesting stuff from the module side. I don't know if the kernel I'm playing with was built with module support because I downloaded it from internet.... now, I just checked and lsmod on the UML guest shows this: Code:
# lsmod Now, another thing I noticed is that when you build stuff like modules for the kernel, ARCH=um has to be set, right? So I tried building my module with ARCH=um included in the make command and now I get a lot of errors: Code:
$ LANG=en make ---------- Post added 04-15-11 at 10:12 AM ---------- Keep in mind I'm building the module on the host, not the UML guest. |
Quote:
Quote:
P.S. lsmod works fine on Slackware 13.1 (default kernel) and /proc/modules is also present here. |
Yes... sounds like I'll have to get my hands dirty and build my own kernel for UML. :-)
I'll feedback after I do it during the weekend. Thanks for your help! |
Well, well. I have already rebuilt the UML kernel by hand (2.6.38.3, by the way) and apparently the one I downloaded off internet didn't have module support built in because in the one I created I do have it.... so after rebuilding my module against the 2.6.38.3 source I was able to load it.... and now the UML kernel is facing an infinite loop after insmodding so I guess I have to start learning how to debug kernel modules. :-)
Anisha, as usual, very very helpful! Thanks! |
Quote:
Quote:
|
It's a module problem.
|
All times are GMT -5. The time now is 11:31 PM. |