Messages in this thread | | | Date | Thu, 18 Mar 2004 12:26:45 +0000 | From | viro@parcelfa ... | Subject | Re: [PATCH] Bind Mount Extensions 0.04.1 3/5 |
| |
On Mon, Mar 15, 2004 at 08:58:14AM +0100, Herbert Poetzl wrote: > -extern int vfs_permission(struct inode *, int); > +extern int vfs_permission(struct inode *, int, struct nameidata *);
Vetoed, along with IS_RDONLY() prototype change.
Note that you are doing exactly the opposite of the changes we'll need to deal with remount races.
What we need is to push readonly checks _up_ - into callers of fs methods. vfs_permission() is default ->permission() - no more, no less. Neither it nor other instances have any business touching "this vfsmount is readonly" logics - it's not something where fs can override stuff; it's "admin said no r/w access here".
IOW, the check for r/w access to file/directory/symlink on a r/o mount should be moved into the callers (very few of them) of ->permission() and away from the methods themselves. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |