Re: udev and devfs - The final word

From: Greg KH
Date: Wed Dec 31 2003 - 14:29:40 EST


On Wed, Dec 31, 2003 at 04:05:59AM +0100, Pascal Schmidt wrote:
> On Wed, 31 Dec 2003 01:40:09 +0100, you wrote in linux.kernel:
>
> > 2) udev does not care about the major/minor number schemes. If the
> > kernel tomorrow switches to randomly assign major and minor numbers
> > to different devices, it would work just fine (this is exactly
> > what I am proposing to do in 2.7...)
>
> Why? I want to keep my static device files in /dev. I don't even have
> hotpluggable devices, and many months do pass before even one piece
> of hardware gets changed (in which case I know what I have to do).
> I don't want to eat any overhead or run any daemons or hotplug agents.

You would not have any "extra" overhead if you don't add any new devices
to your system. udev only runs when /sbin/hotplug runs. As for extra
space on your disk, this email thread is almost as big as the udev
binary is :)

> What benefit would there be in "random" numbers? More compressed number
> space by giving out numbers sequentially?

Yes.

> Or less having to work with the numbers because they become just
> cookies and never need to be inspected except in very small parts of
> the kernel?

That is already happening today in the kernel.

And 2.8 will probably have the "random number" assignment be a compile
option, depending on the maturity of udev. We'll just have to see how
it works out.

thanks,

greg k-h
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/