From owner-freebsd-hackers Sun Apr 28 22:18:26 1996 Return-Path: owner-hackers Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id WAA22161 for hackers-outgoing; Sun, 28 Apr 1996 22:18:26 -0700 (PDT) Received: from ref.tfs.com (ref.tfs.com [140.145.254.251]) by freefall.freebsd.org (8.7.3/8.7.3) with ESMTP id WAA22130 for ; Sun, 28 Apr 1996 22:18:21 -0700 (PDT) Received: (from julian@localhost) by ref.tfs.com (8.7.3/8.6.9) id LAA27576 for hackers@freebsd.org; Fri, 26 Apr 1996 11:58:42 -0700 (PDT) Date: Fri, 26 Apr 1996 11:58:42 -0700 (PDT) From: Julian Elischer Message-Id: <199604261858.LAA27576@ref.tfs.com> To: hackers@FreeBSD.org Subject: devfs policy question. Sender: owner-hackers@FreeBSD.org X-Loop: FreeBSD.org Precedence: bulk Here is policy question number one... What should devfs do to a device that is open when the driver requests that it be deleted? e.g. what should happen to the vnode for /devfs/rsd1s1d if the slice code decides that that device makes no sense any more, but there is a reference because a preocess somewhere has it open.. (what if it's mounted?)? At the moment a vgone() is done on the vnode. is this right? It is dissociated from devfs and vgone (well vclean actually) associates it with the deadfs vnops. Is this the right thing to do? --------------- Policy question number two should devfs allow the creation of fifo/named pipes? I tend to think yes.... they are dynamic and kinda-like devices --------------- Policy question number three When returning a vnode from devfs_lookup() an attempt is made to see if that node already has a vnode associated with it, and if it is not in use, it adds a reference and resurects it. This means that if you have 100 devices, there are 100 vnodes sitting around waiting to be reused. Very few of these would be actually re-used for devices.. Should the devfs try re-use the same vnode (or a small pool of vnodes) again and again for different devices, to avoid thrashing the vnode cache? If so, does anyone have any ideas about how it can know that the vnode that i just gave away with a lookup() is no-longer referenced and can be re-used straight away? (rather than going asking for another... Devfs vnodes want to be put at the end of the LRU Queue, as they can be recreated very quickly (unless there are aliases). julian