It may ask to change kernel parameters for compilation... what driver are you trying to install? I still wonder if you understand this time - If static, that means you will have to compile - not your driver - but a new kernel...
therefore it will no more be a module but more a kernel builtin. It will be built in the new kernel.
There is some problem in static loading of driver which is leading to confusion.
To load the driver statically I followed two ways Process 1) and Process 2).
Earlier I had followed:
Process 1)
The steps are:
1) I built my char driver named demochardrv.ko.
2) I copied the driver in /lib/modules/2.6.34.12/kernel/drivers/char/.
3) I made an entry of it in /etc/modules.
4) Reboot.
But these 4 steps were not working earlier and I did not see my driver in lsmod.
So apart from the above steps I followed the other way:
Process 2)
The steps are as:
1) I added the driver details in file "/lib/modules/2.6.34.12/build/drivers/char/Kconfig":
config DEMOCHARDRV
tristate "TEST DEMO DRIVER'
default n
help
TEST STATIC INSTALL DRIVER
2) I added the driver details in "/lib/modules/2.6.34.12/build/drivers/char/Makefile":
obj-$(CONFIG_DEMOCHARDRV) += demochardrv.o
3) Copied the driver files in /lib/modules/2.6.34.12/build/drivers/char/.
4) Edited the .config file and added CONFIG_DEMOCHARDRV=y.
5) Fired make menuconfig and selected(with either * / M) my driver.
6) Did make, make modules, make modules_install and make install.
7) Reboot
Now the driver was loading at boot time even if I was not selecting it in menuconfig.
To resolve the issue in Process 2 I removed the entry made in /etc/modules. But now the driver was not loading at all.
So I removed the Process 2 steps and again followed Process 1 steps and driver is loading at boot time now.
Now Process 1 is working.
But Process 2 is not working alone and it need additional steps of Process 1.
So I am confused as to which process are correct.
Can anybody pls provide some inputs?