Errors that may occur when Insmod: (question 5 is the actual problem you are experiencing, others are learning from his experience)
1.warning:function declaration isnt a prototype
This kind of error is also very common, mainly for some of the functions of the fixed format of the wrong use. For example, int function () is renamed int function (void)
static int xxxx_init (void) Remember not to lack static, while static void Xxxx_exit (void)
2. The cause of warning:assignment makes pointer from integer without a cast appears
The first may be the problem of type conversion. The return value type of the function, etc.
Second, there is no declaration of the function found in the source file, probably forgot to add the header file. (non-declared function prototypes all default to return int values
3, Makefile:4: * * * missing separator. Stop.
Recently used SourceInsight3.5 editing program, which directly edit the saved Word format. To open in binary mode with Winhex or UltraEdit.
The tab character corresponds to 0x09 and should not be a few 0x20. This is the main use VI to open the file, cut into the end of the line mode, using ": Set FF =unix"
4.hello:version Magic 2.6.30.4 mod_unload ARMv4 should Be2.6.30.4-embedsky mod_unload ARMv4
Insmod:cannot Insert Hello.ko:invalid Module format
Cause of Error: The module version does not match the kernel version!
Workaround: Import the preset configuration information, enter Menuconfig continue to configure General Config, () Local version
Add the following in parentheses: "-embedsky" exits save As. config, recompile the kernel, drive module, and then load the module
AA Insmod Buttons.ko
Buttons:unknown symbol __aeabi_unwind_cpp_pr0 (err 0)
Insmod:can ' t insert ' Buttons.ko ': unknown symbol in module or invalid parameter
Cause: The driver module does not match the kernel image
Workaround: Find the same as the kernel mirror downloaded to the board: modify Makefile
Kern_dir =/work/system/linux-3.4.2 (the kernel image of the original default path)
Change to (kernel image of the path downloaded to the board) Kern_dir =/work/system/linux_suspend/linux-3.4.2
Problems with Linux porting driver Insmod