Subject: Re: Share common code/data across ports?
To: None <firstname.lastname@example.org>
From: Wolfgang Solfrank <email@example.com>
Date: 01/09/1997 20:52:50
> [Note: if the reader tends to respond to new design ideas with "that's not
> how we did it when computers ran on STEAM!", just skip the next two
> paragraphs. Note that I will confess to that reaction on more than one
> (One potential solution, of course, is to abandon device numbers entirely
> and instead pass the entryname down into the open routine; a lot of work,
> but it eliminates the table-version skew problem. Of course, then you *can't*
> call your root device /dev/bert (perhaps you can if it's a symlink, since the
> extracted "real" name of the device would be available). This also gets
> rid of the problem of being unable to increase the number of partitions on
> a disk drive owing to the minor device bit partitioning scheme.
This is what makes this approach quite elegant. I like it very much.
It could, if done right, also eliminate quite a few hacks in the kernel to
handle device aliases.
> If you think that's a hack, it gets worse: when I was at MIT, the V7 CHAOSNET
> implementation special cased namei to not merely make the entryname available
> to the driver, but to be willing to *stop* parsing a pathname in the middle if
> it hit a suitable driver, passing the entire rest of the pathname into the
> open routine; thus you could open a telnet connection with
> "/dev/chaos/223/TELNET" (approximately; this was 18 years ago, and I'm doing
> this from memory). While you may think it grotesque to have parsing routines
> in the kernel (well, OTHER parsing routines besides namei), the ability to
> create simple network tools with "cat" was a wonder. [I then borrowed that
> idea for UNOS, and even managed to preserve it after rearchitecting the
> filesystem code to implement a vnode layer.] )
Note that you while you can't do this in some driver currently, it is possible
to do it with your own filesystem. In fact, there is something already in
there that vaguely resembles this, namely the portal fs.
ws@TooLs.DE (Wolfgang Solfrank, TooLs GmbH) +49-228-985800