Compiling Kernel Module with hierarchy / cross module dependency (say there are EXPORT_SYMBOL in the kernel)
when you insert the child-module, it may cause you following error:
.... Unknown Symbol
You may call the following for further information
$ dmesg
...
[19729.170980] xrawdata0: no symbol version for DmaRegister
[19729.170984] xrawdata0: Unknown symbol DmaRegister
This may occur for all kernel module with kernel version >= 2.6.26
Solution:
1. Divide the Makefile according to the Hierarchy.
2. Make the Base first and let it generate the "Module.symvers".
3. Copy the "Module.symvers" to the directory of the child modules
4.Continue your Compilation and keep renewl the Module.Symvers.
OR
You can make a link of "Module.Symvers" to your kernel source Directory at all your modules source directory to keep your Module.Sysmvers being updated.
Make sure you have run "make vmlinux" before any kernel module compilation.
Topic個名太長...唔係太知係D咩黎...= =
回覆刪除已改
回覆刪除簡單D就係Compile Linux Kernel Module時,
如果Linux Version >= 2.6.26 時會有問題
THX!
回覆刪除