Results 1 to 5 of 5
Hi,
one can use "mknod" to create an new device in the /dev directory in linux.
But this is through the console. If I like to create a device, giving ...
- 03-27-2008 #1
equivalent of mknod
Hi,
one can use "mknod" to create an new device in the /dev directory in linux.
But this is through the console. If I like to create a device, giving the major and minor number, in my code, is there any kernel call for the same???
Any kind of help will be appreciated.
Linux Rocks!!!!
Rinjo
- 03-27-2008 #2
Sure. It's called, um, mknod.
For more information, do this at the shell prompt:
If man pages are not installed on your system, google this:Code:man 2 mknod
and focus on the results that say mknod(2), not mknod(1).Code:man mknod linux
And in case you had already tried this shell command on your system:
and had been disappointed to see only the keyboard command, it turns out that the man command only shows you (in general) the lowest-numbered page. If you want all of them, you can do this at the command line, for example:Code:man mknod
and it will show you all of them, one at a time.Code:man -a mknod
Hope this helps.--
Bill
Old age and treachery will overcome youth and skill.
- 03-28-2008 #3Linux Engineer
- Join Date
- Nov 2004
- Location
- Ft. Polk, LA
- Posts
- 796
If you are more interested, check out the mknod source. It is found in coreutils.
- 03-29-2008 #4
Thanks guys!
I have already found the solution and implemented it, before i read your posts. But your inputs are highly appreciated.
Linux Rocks!!!!
Rinjo
- 07-08-2009 #5Just Joined!
- Join Date
- Apr 2009
- Posts
- 5
Hey Rinjo,
May I know How did you implement it?
Because I am also in verge of implementing through kernel source code?
Thanks,
Saurabh Chokshi


Reply With Quote