Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 18 Sep 1999 13:42:20 -0700 (PDT)
From:      Julian Elischer <julian@whistle.com>
To:        Wayne Cuddy <wayne@crb-web.com>
Cc:        FreeBSD Hackers List <freebsd-hackers@FreeBSD.ORG>
Subject:   Re: what is devfs?
Message-ID:  <Pine.BSF.4.05.9909181322590.19831-100000@home.elischer.org>
In-Reply-To: <Pine.LNX.4.10.9909181421550.22037-100000@crb.crb-web.com>

next in thread | previous in thread | raw e-mail | index | archive | help
DEVFS is an experimental idea.

Both FreeBSD and Linux are experimenting with the concept
of a filesystem type that is used by the  kernel to export it's view of
what devices are present and capable of being used.

in -current, the devfsext.h file is no longer required as the functions it
defines are no longer directly called by the driver (I need to fix the
example drivers) and instead, a function "make_device()" is called . This
is done regradless of whether DEVFS is compiled in, and this function then
calls the DEVFS functions if DEVFS is required.

The theory is that DEVFS allows totally dynamic registration of devices.
This is required in several cases..

1/ many new device drivers, are written and co-ordinating/assigning major
numbers becomes infeasible.. (not happenned yet, but might in the future)

2/ Subdividing devices for sub functions may need to be arbitrary in form,
and it may be infeasible to assign minor numbers in a predefinable
manner... Think of a disk concatination scheme which is doen in the same
framework as a disk partition scheme. Is a BSD partition within a dos
partition the same minor number ans a dos partition within a BSD
partition? And what minor number is a partition of an concattinated drive
made from sub partitions of 3 differnt drives, one of which is divided
using DOS partitions and the other using a BSD partiton within a DOS
partition?  his is presently done with a major hack of assigning a
different major number to the concatinated device.

3/ NFS mounting a / filesystem from (say) NT which can NFS export a
filesystem but cannot export device nodes means that the local system
needs to provide it's own /dev. (this is getting to be less of a problem)
Or, getting a /dev/from Linux, where all the minors are wrong for BSD and
we need to get our own from "somewhere".

DEVFS itself works fine however a subsystem it required to be a useful
abstraction was vandalised and stripped out by some people who "didn't get
it" and it has not yet been replaced by equivalent code. That
functionality is required if you want to mount several local filesystems.
However the current devfs is quite capable of being used in NFS mounted
(netbooted) scenareos.





On Sat, 18 Sep 1999, Wayne Cuddy wrote:

> In the examples device drivers I see the inclusion of devfsext.h.  I read the
> README in the devfs directory but I am still a little unsure what devfs would
> be used for.  Can anyone give me some examples here.  Is there any more
> information pertaining to devfs?
> 
> Thanks in advance,
> Wayne 
> 
> 
> 
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-hackers" in the body of the message
> 



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.05.9909181322590.19831-100000>