I have a question in driver when ever we do
Code:
register_chrdev (major, “name”,*fops)
when major = 0, it returns a dynamically
allocated major number
But the disadvantage is that we can’t create the device nodes because the major number assigned to
your module can’t be guaranteed to always be the same.
How can we retrieve major number from /proc/devices/ before doing mknod .i.e . I dont want to see mknod everytime ,how it can be done dynamically. I think some script file is required to write .