|
Hi Expert, please advise if I did anything wrong when compiling modules
Install Ubuntu 12.04 in virtualbox, clone the source of linux-3.4-sunxi from github, did some code editing and compile the modules with arm-linux-gnueabi-* . But when playing around on Fedora 22, I cannot load the module and receive "Invalid module format" error. Here is the output of modinfo, file and readelf -h, any clues?
output of modinfo of bundled sunxi-ir-rx.ko
- filename: /lib/modules/3.4.39/kernel/drivers/input/keyboard/sunxi-ir-rx.ko
- license: GPL
- author: DanielWang
- description: Remote IR driver
- depends:
- intree: Y
- vermagic: 3.4.39 SMP preempt mod_unload modversions ARMv7 p2v8
- parm: debug_mask:int
Copy code output of modinfo of my built, named sunxi-ir-rx-hf.ko
- filename: /lib/modules/3.4.39/kernel/drivers/input/keyboard/sunxi-ir-rx-hf.ko
- license: GPL
- author: DanielWang
- description: Remote IR driver
- srcversion: 2CEDB65025BE20B385A4605
- depends:
- vermagic: 3.4.39 SMP preempt mod_unload modversions ARMv7 p2v8
- parm: debug_mask:int
- parm: IR_RXFILT_VAL:int
- parm: IR_RXIDLE_VAL:int
- parm: IR_ACTIVE_T:int
- parm: IR_ACTIVE_T_C:int
- parm: IR_L1_MIN:int
- parm: IR_L0_MIN:int
- parm: IR_PMAX:int
- parm: IR_DMID:int
- parm: IR_DMAX:int
Copy code output of file of bundled sunxi-ir-rx.ko
- sunxi-ir-rx.ko: ELF 32-bit LSB relocatable, ARM, EABI5 version 1 (SYSV), BuildID[sha1]=32e092d5e778c85bdc07d5e8e54038d53f574f0a, not stripped
Copy code output of file of my built, named sunxi-ir-rx-hf.ko
- sunxi-ir-rx-hf.ko: ELF 32-bit LSB relocatable, ARM, EABI5 version 1 (SYSV), BuildID[sha1]=40b3f4abf5c4d2f38aa599a52c126adaee6ed1ee, not stripped
Copy code output of readelf -h of bundled sunxi-ir-rx.ko
- ELF Header:
- Magic: 7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00
- Class: ELF32
- Data: 2's complement, little endian
- Version: 1 (current)
- OS/ABI: UNIX - System V
- ABI Version: 0
- Type: REL (Relocatable file)
- Machine: ARM
- Version: 0x1
- Entry point address: 0x0
- Start of program headers: 0 (bytes into file)
- Start of section headers: 80916 (bytes into file)
- Flags: 0x5000000, Version5 EABI
- Size of this header: 52 (bytes)
- Size of program headers: 0 (bytes)
- Number of program headers: 0
- Size of section headers: 40 (bytes)
- Number of section headers: 54
- Section header string table index: 51
Copy code
output of readelf -h of my built, named sunxi-ir-rx-hf.ko
- ELF Header:
- Magic: 7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00
- Class: ELF32
- Data: 2's complement, little endian
- Version: 1 (current)
- OS/ABI: UNIX - System V
- ABI Version: 0
- Type: REL (Relocatable file)
- Machine: ARM
- Version: 0x1
- Entry point address: 0x0
- Start of program headers: 0 (bytes into file)
- Start of section headers: 80860 (bytes into file)
- Flags: 0x5000000, Version5 EABI
- Size of this header: 52 (bytes)
- Size of program headers: 0 (bytes)
- Number of program headers: 0
- Size of section headers: 40 (bytes)
- Number of section headers: 54
- Section header string table index: 51
Copy code
output of insmod of my built
- insmod: ERROR: could not insert module sunxi-ir-rx-hf.ko: Invalid module format
Copy code *No output for bundled sunxi-ir-rx.ko, since it is loaded successfully
|
|