Messages in this thread | | | From | Kay Sievers <> | Date | Wed, 12 Aug 2009 18:23:48 +0200 | Subject | Re: automagic udev device node creation? |
| |
On Wed, Aug 12, 2009 at 18:04, Sander, Tim<Tim.Sander@hbm.com> wrote: > I have written a simple mmap test driver which seems to work so far.=20 > The only problem i have, is that no udev device node is automatically = > created?=20 > So i really would like to know what part is missing to make udev = > automatically create > the device node? > > Everything works alright if i just create the device node by hand. > > I suspect that these should be created out of the sysfs information = > created by the module.
Assign the "devt" value in the registered "struct device" with the major/minor value of your device instance.
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=blob;f=include/linux/device.h;h=aebb81036db2d368a7b55664f5a2b9d102c5109d;hb=HEAD#l407
Kay
| |