All of
 help / color / mirror / Atom feed
From: David Howells <>
To: Miklos Szeredi <>
Cc:, Alexander Viro <>,
	Matthew Wilcox <>, Ian Kent <>,
	Linus Torvalds <>,,
Subject: Re: [RFC][PATCH 0/3] vfs: Use an xarray instead of inserted bookmarks to scan mount list
Date: Mon, 15 Mar 2021 13:41:48 +0000	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

Miklos Szeredi <> 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.


  parent reply	other threads:[~2021-03-15 13:42 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-15 12:07 [RFC][PATCH 0/3] vfs: Use an xarray instead of inserted bookmarks to scan mount list David Howells
2021-03-15 12:07 ` [PATCH 1/3] vfs: Use an xarray in the mount namespace to handle /proc/mounts list David Howells
2021-03-15 12:07 ` [PATCH 2/3] vfs: Use the mounts_to_id array to do /proc/mounts and co David Howells
2021-03-15 12:54   ` Matthew Wilcox
2021-03-15 12:08 ` [PATCH 3/3] vfs: Remove mount list trawling cursor stuff David Howells
2021-03-15 12:46 ` [RFC][PATCH 0/3] vfs: Use an xarray instead of inserted bookmarks to scan mount list Matthew Wilcox
2021-03-15 13:14 ` Miklos Szeredi
2021-03-15 13:17   ` Matthew Wilcox
2021-03-15 13:41 ` David Howells [this message]
2021-03-15 14:22   ` Miklos Szeredi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.