From owner-cvs-all Sat Aug 14 15: 3:34 1999 Delivered-To: cvs-all@freebsd.org Received: from awfulhak.org (dynamic-98.max1-du-ws.dialnetwork.pavilion.co.uk [212.74.8.98]) by hub.freebsd.org (Postfix) with ESMTP id 953A815228; Sat, 14 Aug 1999 15:03:27 -0700 (PDT) (envelope-from brian@Awfulhak.org) Received: from keep.lan.Awfulhak.org (root@keep.lan.Awfulhak.org [172.16.0.8]) by awfulhak.org (8.9.3/8.9.3) with ESMTP id VAA10626; Sat, 14 Aug 1999 21:12:28 +0100 (BST) (envelope-from brian@lan.awfulhak.org) Received: from keep.lan.Awfulhak.org (brian@localhost.lan.Awfulhak.org [127.0.0.1]) by keep.lan.Awfulhak.org (8.9.3/8.9.3) with ESMTP id VAA07985; Sat, 14 Aug 1999 21:14:35 +0100 (BST) (envelope-from brian@keep.lan.Awfulhak.org) Message-Id: <199908142014.VAA07985@keep.lan.Awfulhak.org> X-Mailer: exmh version 2.0.2 2/24/98 To: Poul-Henning Kamp Cc: Brian Somers , Julian Elischer , cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/miscfs/specfs spec_vnops.c src/sys/sys conf.h In-reply-to: Your message of "Sat, 14 Aug 1999 07:17:15 +0200." <9343.934607835@critter.freebsd.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sat, 14 Aug 1999 21:14:35 +0100 From: Brian Somers Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk > >One possibility would be to support generic devices - /dev/tun for > >example rather than /dev/tun*. It'd be amazing to have /dev/pty too > >:-) > > This is different and unrelated. I have already fixed pty so that > there is no "NPTY" anymore, you can just open any random pty and the > kernel will create it on the fly. The same stunt can be done with > tun, it is really easy. Not being limited by magic numbers in your kernel config file is definitely a win, but the real win is to be able to open /dev/tun (or /dev/pty) and ``just get one''. I really don't care which one I get - I just want any one. The objective here is to not require a boat-load of entries in /dev/, and to not need to attempt N open()s just because there's already N similar devices open. From what I can tell, this requires that the driver ignores the minor number ('cos it's the same for all accesses) but keeps a track of of the process id in the device structure. The driver would need to know about fork()s and *all* close()s, and would probably need to use something faster than `sequential' to find the device structure from the pid (some sort of hash). I thought about doing this myself, but didn't because the close() bit was too scary - think of all the 3rd party stuff that'd break. > -- > Poul-Henning Kamp FreeBSD coreteam member > phk@FreeBSD.ORG "Real hackers run -current on their laptop." > FreeBSD -- It will take a long time before progress goes too far! -- Brian Don't _EVER_ lose your sense of humour ! To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message