Re: [RFC][PATCH 0/3] vfs: Use an xarray instead of inserted bookmarks to scan mount list

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Mar 15, 2021 at 2:41 PM David Howells <dhowells@xxxxxxxxxx> wrote:
>
> Miklos Szeredi <miklos@xxxxxxxxxx> wrote:
>
> > >  (2) We can use the file position to represent the mnt_id and can jump to
> > >      it directly - ie. using seek() to jump to a mount object by its ID.
> >
> > What happens if the mount at the current position is removed?
>
> umount_tree() requires the namespace_sem to be writelocked, so that should be
> fine as the patches currently read-lock that whilst doing /proc/*/mount*
>
> I'm assuming that kern_unmount() won't be a problem as it is there to deal
> with mounts made by kern_mount() which don't get added to the mount list
> (mnt_ns is MNT_NS_INTERNAL).  kern_unmount_array() seems to be the same
> because overlayfs gives it mounts generated by clone_private_mount().  It
> might be worth putting a WARN_ON() in kern_unmount() to require this.
>
> When reading through proc, m_start() calls xas_find() which returns the entry
> at the starting index or, if not present, the next higher entry.

This will break the property of new mounts always being added to the
end of the list.  That's likely a regression for nerural based parsers
(i.e. people), probably less so for machine parsers.

Thanks,
Miklos

>
> David
>



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux