Character Device driver: How to load it automatically ?
Hi friends,
this is swanand. I have written a character device driver. I use this the functionalities of this driver only sometimes acording to the schedule. So i wanted to install the modules inside the kernel from my application program. In the init_module, i register the device and print its major number using printk statement. Then i use mknod to create a device file. I also tried to use system("insmod ./char.ko > fp"); to redirect the major number to a file through which i will read later, but didn't work. Can anyone please tell me how do i install my character device driver with the system through my program ? My problem is that how do come to know the major number which gets dynamically allocated during my init_module(). Thank you. Warmth and regards, Swanand Shende. :newbie: |
All times are GMT -5. The time now is 01:25 PM. |