]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
fs: use boolean to indicate anonymous mount namespace
authorChristian Brauner <brauner@kernel.org>
Mon, 10 Nov 2025 15:08:22 +0000 (16:08 +0100)
committerChristian Brauner <brauner@kernel.org>
Tue, 11 Nov 2025 09:01:31 +0000 (10:01 +0100)
commitd9a44089ac7754e470dfdaf3658c3455b2d7f7dd
treef2328d7cb80a77dbd9d1459c38ffad0557d72378
parent6bf253855aa8c970d2191f87ee23f9f184ddaa79
fs: use boolean to indicate anonymous mount namespace

Stop playing games with the namespace id and use a boolean instead:

* This will remove the special-casing we need to do everywhere for mount
  namespaces.

* It will allow us to use asserts on the namespace id for initial
  namespaces everywhere.

* It will allow us to put anonymous mount namespaces on the namespaces
  trees in the future and thus make them available to statmount() and
  listmount().

Link: https://patch.msgid.link/20251110-work-namespace-nstree-fixes-v1-10-e8a9264e0fb9@kernel.org
Signed-off-by: Christian Brauner <brauner@kernel.org>
fs/mount.h
fs/namespace.c