From owner-freebsd-current Tue Oct 10 20:39:23 1995 Return-Path: owner-current Received: (from root@localhost) by freefall.freebsd.org (8.6.12/8.6.6) id UAA20408 for current-outgoing; Tue, 10 Oct 1995 20:39:23 -0700 Received: from phaeton.artisoft.com (phaeton.Artisoft.COM [198.17.250.211]) by freefall.freebsd.org (8.6.12/8.6.6) with ESMTP id UAA20403 ; Tue, 10 Oct 1995 20:39:20 -0700 Received: (from terry@localhost) by phaeton.artisoft.com (8.6.11/8.6.9) id UAA12252; Tue, 10 Oct 1995 20:36:43 -0700 From: Terry Lambert Message-Id: <199510110336.UAA12252@phaeton.artisoft.com> Subject: FS LAYERING PATCHES AGAINST CURRENT UPLOADED To: hackers@freebsd.org, current@freebsd.org Date: Tue, 10 Oct 1995 20:36:42 -0700 (MST) Cc: terry@phaeton.artisoft.com (Terry Lambert) X-Mailer: ELM [version 2.4 PL24] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Content-Length: 2475 Sender: owner-current@freebsd.org Precedence: bulk I have uploaded the FS layering patches I promised last week. They are in ~terry/fs_layer_patch.gz on freefall.crom.com. These patches apply to all file system types in the -current distribution. If you are developing a file system and it is not in the -current tree, you will need to retrofit your FS. For example: John Dyson: You will need to remove the explicit cn_pnbuf freeing in your port of the ext2fs. This is now done explicitly by the caller. These fix the protocol layering violations in the Heidemann framework as it had been pounded into the 4.4BSD lite code. The kern/vfs_syscalls.c has been almost totally rewritten to use full negative logic. A patch to vfs_lookup.c is not included in this release, but will get rid of the "bogus_namei:" labels when that is done (the patch is obvious from the code, as the code is commented to that effect). I can supply kern/vfs_syscalls.c as a seperate file if the patch is considered too complex. The code is completely functional and had been regression tested. These patches also add a line to vnode_if.h and vnode_if.c by way of mods to the kern/vnode_if.sh. This line is an explicit ops count, which gets rid of the counter in kern/vfs_init.c. This was necessary to allow booting with zero file system types defined. This same fix fixes preinitialization file system module loading, which use to fail for the first file system type. This is a total of about a 5 line change altogether, but it is a large step towards making the object files the same for FS LKMs and for statically loadable LKMs. Included in this patch set are some NFS fixes for three bugs that would cause the system to eventually panic by multiply freeing path name buffers onto the freelist when accessed via a PCNFS implementation that did not check the existence of a file/directory before attempting a create. In addition, there are some similar bugs (two of them) fixed in the vfs_syscalls.c code by the rewrite. AFTER APPLYING THESE PATCHES, YOU *MUST* REBUILD YOUR KERNEL BUILD DIRECTORY FROM SCRATCH. THESE PATCHES MODIFY THE kern/vnode_if.sh SCRIPT, WHICH GENERATES THE vnode_if.c AND vnode_if.h FILES IN A KERNEL BUILD!!! THEY ALSO REDEFINE THE SEMANTICS OF BUFFER SAVING: YOU *WILL* HAVE A MEMORY LEAK IF YOU DON'T FULLY REBUILD YOUR KERNEL FROM SCRATCH! Regards, Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers.