Driver can not be inserted with error "inserting gedv0.ko: -1 Invalid mosule format"
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
When I did make prepare and configured the kernel, I entered return as all options. Is that a problem. I am trying relate the kernel configuration to the 'current_stack_pointer' error.
I'm not an expert on ARM but I think 'invialid register name for 'current_stack_pointer' is some wrong inline assembly code. I had a look at the kernel sources and found that symbol only for the sh, mn10300 and and x86 architecture defined but not for arm. Where does this error come from? Can you post the whole output of make? Did you do "make prepare" and "make *config" with the same arguments as the compilation (ARCH=arm, CROSS_COMPILE=arm-...)? It seems that somehow different architectures are mixed ...
So if compile a module for arm processor, then the kernel has to be compied with arm compiler? After removing the arm compileing option in makefile, it compiles ok and modinfo display the right version number, but file check reaveals intel 80386 format.
If you remove the ARCH=arm option from the makefile, the architecture of the host system (I assume x86) will be selected and thus elf32-i386 output will be created. You have to do all things like "make prepare", "make menuconfig" with the options "ARCH=arm CROSS_COMPILE=...".
Enter "make distclean" and then reconfigure the kernel.
I redid everything with the arm-none-linux option. Now I was able to create the right module and inserted into the target. I would like to say thank you very mouch for your persistent help for these few days.
I have a different question. Once the kernel module is inserted, do we need to do anything in order to be able to call the functions in the kernel module? It seems like I have trouble accessing the kernel module that I have just insterted.
Now I have to compile a kernel module for another kernel linux-2.6.30-rc7. But when I do make prepare, I have following erros:
cripts/kconfig/conf -s arch/arm/Kconfig
CHK include/linux/version.h
Generating include/asm-arm/mach-types.h
CHK include/linux/utsrelease.h
UPD include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
In file included from include/linux/compiler-gcc.h:86,
from include/linux/compiler.h:40,
from include/linux/stddef.h:4,
from include/linux/posix_types.h:4,
from include/linux/types.h:14,
from include/linux/page-flags.h:8,
from kernel/bounds.c:9:
include/linux/compiler-gcc4.h:8:4: error: #error Your version of gcc miscompiles the __weak directive
make[1]: *** [kernel/bounds.s] Error 1
make: *** [prepare0] Error 2
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.