From: Christian Brauner <brauner@kernel.org>
To: linux-man@vger.kernel.org,
Alejandro Colomar <alx.manpages@gmail.com>,
Michael Kerrisk <mtk.manpages@gmail.com>
Cc: Christian Brauner <brauner@kernel.org>,
Christoph Hellwig <hch@infradead.org>,
Aleksa Sarai <cyphar@cyphar.com>
Subject: [PATCH 1/4] mount_setattr.2: add and explain missing EBUSY error
Date: Tue, 7 Jun 2022 15:38:17 +0200 [thread overview]
Message-ID: <20220607133820.1721352-2-brauner@kernel.org> (raw)
In-Reply-To: <20220607133820.1721352-1-brauner@kernel.org>
In order to ID-map a mount it must not have any writers. If the mount
has writers and the caller tries to ID-map the mount EBUSY will be
returned.
Signed-off-by: Christian Brauner (Microsoft) <brauner@kernel.org>
---
man2/mount_setattr.2 | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/man2/mount_setattr.2 b/man2/mount_setattr.2
index 77233f589..2bf1b24da 100644
--- a/man2/mount_setattr.2
+++ b/man2/mount_setattr.2
@@ -429,6 +429,13 @@ The caller tried to change the mount to
.BR MOUNT_ATTR_RDONLY ,
but the mount still holds files open for writing.
.TP
+.B EBUSY
+The caller tried to create an ID-mapped mount raising
+.BR MOUNT_ATTR_IDMAP
+and specifying
+.I userns_fd
+but the mount still holds files open for writing.
+.TP
.B EINVAL
The pathname specified via the
.I dirfd
@@ -662,6 +669,9 @@ This also implies that the ID mapping of a mount cannot be altered.
The mount must be a detached mount;
that is,
it must have been created by calling
+.IP \(bu
+The mount must not have any writers.
+.\" commit 1bbcd277a53e08d619ffeec56c5c9287f2bf42f
.BR open_tree (2)
with the
.B OPEN_TREE_CLONE
--
2.34.1
next prev parent reply other threads:[~2022-06-07 13:38 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-07 13:38 [PATCH 0/4] mount_setattr.2: updates Christian Brauner
2022-06-07 13:38 ` Christian Brauner [this message]
2022-06-07 13:38 ` [PATCH 2/4] mount_setattr.2: update conditions to create ID-mapped mounts Christian Brauner
2022-06-07 13:38 ` [PATCH 3/4] mount_setattr.2: update list of supported filesystems Christian Brauner
2022-06-07 13:38 ` [PATCH 4/4] mount_setattr.2: ffix Christian Brauner
2022-06-08 15:26 ` [PATCH 0/4] mount_setattr.2: updates Alejandro Colomar
2022-06-08 15:28 ` Alejandro Colomar
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:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220607133820.1721352-2-brauner@kernel.org \
--to=brauner@kernel.org \
--cc=alx.manpages@gmail.com \
--cc=cyphar@cyphar.com \
--cc=hch@infradead.org \
--cc=linux-man@vger.kernel.org \
--cc=mtk.manpages@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* 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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox