Date: Sat, 18 Dec 1999 20:05:04 +0000 (GMT) From: Terry Lambert <tlambert@primenet.com> To: peter@netplex.com.au (Peter Wemm) Cc: tlambert@primenet.com, robert+freebsd@cyrus.watson.org, freebsd-fs@FreeBSD.ORG Subject: Re: Request for objections: extended attribute and ACL interfaces Message-ID: <199912182005.NAA01764@usr08.primenet.com> In-Reply-To: <19991217190222.25B3F1C03@overcee.netplex.com.au> from "Peter Wemm" at Dec 18, 99 03:02:22 am
next in thread | previous in thread | raw e-mail | index | archive | help
> Terry, why don't you freaking well *look* at the code every now and then? > This *is* implemented and works already, for over a year now. > > kern/vfs_init.c: > ---------------------------- > revision 1.39 > date: 1998/11/10 09:04:09; author: peter; state: Exp; lines: +223 -125 > Make the vnode opv vector construction fully dynamic. Previously we > leaked memory on each unload and were limited to items referenced in > the kernel copy of vnode_if.c. Now a kernel module is free to create > it's own VOP_FOO() routines and the rest of the system will happily > deal with it, including passthrough layers like union/umap/etc. > > Have VFS_SET() call a common vfs_modevent() handler rather than > inline duplicating the common code all over the place. > > Have VNODEOP_SET() have the vnodeops removed at unload time (assuming a > module) so that the vop_t ** vector is reclaimed. > > Slightly adjust the vop_t ** vectors so that calling slot 0 is a panic > rather than a page fault. This could happen if VOP_something() was called > without *any* handlers being present anywhere (including in vfs_default.c). > slot 1 becomes the default vector for the vnodeop table. > > TODO: reclaim zones on unload (eg: nfs code) > ---------------------------- Peter, it should work without any handlers being present. At the FreeBSDCon, Kirk agreed that the vfs_default.c stuff damaged the abstraction between UFS and FFS layers, which are supposed to be seperated as block management policy and directory hierarchy policy layers. Ask Matt Dillon or Poul-Henning. Peter, there is no rendevous by name for new VOPs so that they can be passed from a loaded stacking layer that knows about a new VOP to an underlying stacking layer that knows about the new VOP, through one that doesn't. For example, an ACLFS layer mounted over top of a translucent FS mounted over top of a read only FS and backing media so that I can put ACLs on the contents of my CDROM that I'm making available to user on my system. If the backing media already knows about VOP_ACL, you are screwed: it's not the same VOP_ACL, unless you imply a dependency between kernel modules that you should not be implying. Peter, the decriptor list isn't sorted so that a dereference can be done by index. Not only is the overhead for this higher, the addition of a new VOP is an O(3) random traversal instead of O(1) linear traversal for existing instanced VFSs. This change is incomplete; it does not fully solve the problem noted in my previous email. Don't assume the code is right and I am wrong, just because you are emotionally invested in the code. Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-fs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199912182005.NAA01764>