Results 1 to 6 of 6
Hi,
I am having doubt on how to create device file for usb.
and how to assign major no to it.
could anybody please tell me this.
thanx in advance...
- 10-31-2007 #1Just Joined!
- Join Date
- Nov 2006
- Location
- Hyderabad
- Posts
- 85
how to create device file
Hi,
I am having doubt on how to create device file for usb.
and how to assign major no to it.
could anybody please tell me this.
thanx in advance
- 10-31-2007 #2
If you've got kernel source, you can look in the file devices.txt. This contains major nodes for all devices. You might also find the man page for MAKEDEV useful.
"I'm just a little old lady; don't try to dazzle me with jargon!"
- 11-01-2007 #3Just Joined!
- Join Date
- Nov 2006
- Location
- Hyderabad
- Posts
- 85
hi hazel,
thank you for reply, but in my system iam not having kernel source code.
i seen code for usb on www.lxr.linux.no & i successfully compiled sample code usb-skeleton.c. But i got struct at creating device file for it.
- 11-01-2007 #4"I'm just a little old lady; don't try to dazzle me with jargon!"
- 11-02-2007 #5Just Joined!
- Join Date
- Nov 2006
- Location
- Hyderabad
- Posts
- 85
thank u i will go through that & get back to you
- 11-05-2007 #6
Hi,
We create a device node by using the command "mknod".
Instead of assigning a major number explicitly, go for dynamic allocation of the major number which assigns the free major number.


Reply With Quote
