Regarding issue using manual steps in using KBUILD

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

Currently one of our client is using a customized Make script so that
they can build the kernel module in their buildsystem. Make script
follows following steps

1. Create .o for all .c files

2. Creates final module.o with all the above .o files

3. Using modpost creates Module.markers (Below is the command I see
getting executed when using 2.6.32 kernel)

/lib/modules/2.6.32.58/source/scripts/mod/modpost  -i
/lib/modules/2.6.32.58/source/Module.symvers -S -K
/lib/modules/2.6.32.58/source/Module.markers -M  ../l2/Module.markers
../l2/l2_module.o

I guess this step creates modulename.mod.c file once successful.

4. Now create modulename.mod.o file.

5. Finally link up everything creating .ko file.

Above steps works great with 2.6.32 kernel but When I am trying the
same on 3.6 kernel Step-3 doesn't return anything other than Error 1
at the end.

Seems Modpost is one tough nut to crack as it has doesn't have any
options or debug logs to display its output status. So I built modpost
with -g option.
In modpost main function read_symbols function is called with input as
"/lib/modules/3.6.10/source/Module.symvers" which in turn calls
read_elf function which is failing currently.

I know its the dirty way where we need to fix makefile for every
kernel version. I would like to know is there something which got
changed after 2.6.32 kernel which is causing the MODPOST to fail.

Any inputs would be of great help. Thanks in advance.

Regards,
Ajith
--------------------------------------------
codingfreak.blogspot.com
--
To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux&nblp;USB Development]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite Secrets]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux