Re: [PATCH] VFS autmounter support v2

viro
2003-06-19T15:20:55Z

On Thu, Jun 19, 2003 at 11:13:42AM -0400, Mike Waychison wrote:

> Introducing special trap vfsmounts w/o super_blocks means we can no
> longer have arbitrary actions on those traps. AFS wants to define what
> happens in kernelspace, autofs wants to define it in userspace. Last I
> checked, vfsmount doesn't have an ops structure.

It would have send an event over attached opened file. Attached at
creation time.

> This only works for mounts performed in kernel space. It doesn't lend
> itself to performing mounts in userspace and would force autofs to
> re-implement mount(1) parsing/struct packing in kernelspace. Definitely
> not a good solution.

Or if passed event contains opened mountpoint-to-be.

> I'm still partial to the idea that a usenamespace ioctl on
> /proc/<pid>/mounts is a cleaner solution in the long run, both for
> automounting as well as for administration tools.

Vetoed. ioctl() is _not_ an acceptable way to implement any generic
functionality. It basically says "my interface is a garbage".

And yes, we need to think about a new syscall for mount-related
work. With sane API - mount(2) one is _not_. sys_mount() would
still stay, obviously.