<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/fs/mnt_idmapping.c, branch v6.12.91</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.12.91</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.12.91'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2024-09-24T22:29:42+00:00</updated>
<entry>
<title>Merge tag 'fuse-update-6.12' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse</title>
<updated>2024-09-24T22:29:42+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2024-09-24T22:29:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f7fccaa772718f6d2e798dece4a5210fe4c406ec'/>
<id>urn:sha1:f7fccaa772718f6d2e798dece4a5210fe4c406ec</id>
<content type='text'>
Pull fuse updates from Miklos Szeredi:

 - Add support for idmapped fuse mounts (Alexander Mikhalitsyn)

 - Add optimization when checking for writeback (yangyun)

 - Add tracepoints (Josef Bacik)

 - Clean up writeback code (Joanne Koong)

 - Clean up request queuing (me)

 - Misc fixes

* tag 'fuse-update-6.12' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse: (32 commits)
  fuse: use exclusive lock when FUSE_I_CACHE_IO_MODE is set
  fuse: clear FR_PENDING if abort is detected when sending request
  fs/fuse: convert to use invalid_mnt_idmap
  fs/mnt_idmapping: introduce an invalid_mnt_idmap
  fs/fuse: introduce and use fuse_simple_idmap_request() helper
  fs/fuse: fix null-ptr-deref when checking SB_I_NOIDMAP flag
  fuse: allow O_PATH fd for FUSE_DEV_IOC_BACKING_OPEN
  virtio_fs: allow idmapped mounts
  fuse: allow idmapped mounts
  fuse: warn if fuse_access is called when idmapped mounts are allowed
  fuse: handle idmappings properly in -&gt;write_iter()
  fuse: support idmapped -&gt;rename op
  fuse: support idmapped -&gt;set_acl
  fuse: drop idmap argument from __fuse_get_acl
  fuse: support idmapped -&gt;setattr op
  fuse: support idmapped -&gt;permission inode op
  fuse: support idmapped getattr inode op
  fuse: support idmap for mkdir/mknod/symlink/create/tmpfile
  fuse: support idmapped FUSE_EXT_GROUPS
  fuse: add an idmap argument to fuse_simple_request
  ...
</content>
</entry>
<entry>
<title>fs/mnt_idmapping: introduce an invalid_mnt_idmap</title>
<updated>2024-09-23T09:07:55+00:00</updated>
<author>
<name>Alexander Mikhalitsyn</name>
<email>aleksandr.mikhalitsyn@canonical.com</email>
</author>
<published>2024-09-06T14:34:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ffcdc4c628e1a30489da10dd78358e89c823b341'/>
<id>urn:sha1:ffcdc4c628e1a30489da10dd78358e89c823b341</id>
<content type='text'>
Link: https://lore.kernel.org/linux-fsdevel/20240904-baugrube-erhoben-b3c1c49a2645@brauner/
Suggested-by: Christian Brauner &lt;brauner@kernel.org&gt;
Signed-off-by: Alexander Mikhalitsyn &lt;aleksandr.mikhalitsyn@canonical.com&gt;
Reviewed-by: Christian Brauner &lt;brauner@kernel.org&gt;
Signed-off-by: Miklos Szeredi &lt;mszeredi@redhat.com&gt;
</content>
</entry>
<entry>
<title>mnt_idmapping: Use kmemdup_array instead of kmemdup for multiple allocation</title>
<updated>2024-08-30T06:22:41+00:00</updated>
<author>
<name>Yu Jiaoliang</name>
<email>yujiaoliang@vivo.com</email>
</author>
<published>2024-08-23T01:55:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=75e4c6bcb88a60402c71ae87328813babb0e679a'/>
<id>urn:sha1:75e4c6bcb88a60402c71ae87328813babb0e679a</id>
<content type='text'>
Let the kememdup_array() take care about multiplication and possible
overflows.

v2:Add a new modification for reverse array.

Signed-off-by: Yu Jiaoliang &lt;yujiaoliang@vivo.com&gt;
Link: https://lore.kernel.org/r/20240823015542.3006262-1-yujiaoliang@vivo.com
Reviewed-by: Jan Kara &lt;jack@suse.cz&gt;
Signed-off-by: Christian Brauner &lt;brauner@kernel.org&gt;
</content>
</entry>
<entry>
<title>fs/mnt_idmapping.c: Return -EINVAL when no map is written</title>
<updated>2024-02-08T09:12:37+00:00</updated>
<author>
<name>Taylor Jackson</name>
<email>taylor.a.jackson@me.com</email>
</author>
<published>2024-02-08T03:02:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=dacfd001eaf252a81537aece602ae2fc16e6ebd5'/>
<id>urn:sha1:dacfd001eaf252a81537aece602ae2fc16e6ebd5</id>
<content type='text'>
Currently, it is possible to create an idmapped mount using a user
namespace without any mappings. However, this yields an idmapped
mount that doesn't actually map the ids. With the following change,
it will no longer be possible to create an idmapped mount when using
a user namespace with no mappings, and will instead return EINVAL,
an “invalid argument” error code.

Reviewed-by: Christian Brauner &lt;brauner@kernel.org&gt;
Signed-off-by: Taylor Jackson &lt;taylor.a.jackson@me.com&gt;
Link: https://lore.kernel.org/r/20240208-mnt-idmap-inval-v2-1-58ef26d194e0@me.com
Signed-off-by: Christian Brauner &lt;brauner@kernel.org&gt;
</content>
</entry>
<entry>
<title>mnt_idmapping: decouple from namespaces</title>
<updated>2023-11-28T13:08:47+00:00</updated>
<author>
<name>Christian Brauner</name>
<email>brauner@kernel.org</email>
</author>
<published>2023-11-22T12:44:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=783822e44594639848b78d4bb61dde26fba04e05'/>
<id>urn:sha1:783822e44594639848b78d4bb61dde26fba04e05</id>
<content type='text'>
There's no reason we need to couple mnt idmapping to namespaces in the
way we currently do. Copy the idmapping when an idmapped mount is
created and don't take any reference on the namespace at all.

We also can't easily refcount struct uid_gid_map because it needs to
stay the size of a cacheline otherwise we risk performance regressions
(Ignoring for a second that right now struct uid_gid_map isn't actually
 64 byte but 72 but that's a fix for another patch series.).

Link: https://lore.kernel.org/r/20231122-vfs-mnt_idmap-v1-3-dae4abdde5bd@kernel.org
Reviewed-by: Josef Bacik &lt;josef@toxicpanda.com&gt;
Signed-off-by: Christian Brauner &lt;brauner@kernel.org&gt;
</content>
</entry>
<entry>
<title>mnt_idmapping: remove nop check</title>
<updated>2023-11-28T13:08:47+00:00</updated>
<author>
<name>Christian Brauner</name>
<email>brauner@kernel.org</email>
</author>
<published>2023-11-22T12:44:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=90fbd8b175ee75ee3d37d748b92bc317660b586d'/>
<id>urn:sha1:90fbd8b175ee75ee3d37d748b92bc317660b586d</id>
<content type='text'>
All mounts default to nop_mnt_idmap and we don't allow creating idmapped
mounts that reuse the idmapping of the filesystem. So unless someone
passes a non-superblock namespace to these helpers this check will
always be false. Remove it and replace it with a simple check for
nop_mnt_idmap.

Link: https://lore.kernel.org/r/20231122-vfs-mnt_idmap-v1-2-dae4abdde5bd@kernel.org
Signed-off-by: Christian Brauner &lt;brauner@kernel.org&gt;
</content>
</entry>
<entry>
<title>mnt_idmapping: remove check_fsmapping()</title>
<updated>2023-11-28T13:08:47+00:00</updated>
<author>
<name>Christian Brauner</name>
<email>brauner@kernel.org</email>
</author>
<published>2023-11-22T12:44:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=e65a29f0235a438ece414d2d99bbf0d31aa97d04'/>
<id>urn:sha1:e65a29f0235a438ece414d2d99bbf0d31aa97d04</id>
<content type='text'>
The helper is a bit pointless. Just open-code the check.

Link: https://lore.kernel.org/r/20231122-vfs-mnt_idmap-v1-1-dae4abdde5bd@kernel.org
Signed-off-by: Christian Brauner &lt;brauner@kernel.org&gt;
</content>
</entry>
<entry>
<title>fs: export mnt_idmap_get/mnt_idmap_put</title>
<updated>2023-11-03T22:28:33+00:00</updated>
<author>
<name>Alexander Mikhalitsyn</name>
<email>aleksandr.mikhalitsyn@canonical.com</email>
</author>
<published>2023-08-07T13:26:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=1b90344614cc5949666328b37f03edec1d4e2873'/>
<id>urn:sha1:1b90344614cc5949666328b37f03edec1d4e2873</id>
<content type='text'>
These helpers are required to support idmapped mounts in CephFS.

Cc: linux-fsdevel@vger.kernel.org
Signed-off-by: Alexander Mikhalitsyn &lt;aleksandr.mikhalitsyn@canonical.com&gt;
Reviewed-by: Christian Brauner &lt;brauner@kernel.org&gt;
Signed-off-by: Ilya Dryomov &lt;idryomov@gmail.com&gt;
</content>
</entry>
<entry>
<title>fs: move mnt_idmap</title>
<updated>2023-01-19T08:24:30+00:00</updated>
<author>
<name>Christian Brauner</name>
<email>brauner@kernel.org</email>
</author>
<published>2023-01-13T11:49:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3707d84c13670bf09b4a9a4dc6733326d8344b31'/>
<id>urn:sha1:3707d84c13670bf09b4a9a4dc6733326d8344b31</id>
<content type='text'>
Now that we converted everything to just rely on struct mnt_idmap move it all
into a separate file. This ensure that no code can poke around in struct
mnt_idmap without any dedicated helpers and makes it easier to extend it in the
future. Filesystems will now not be able to conflate mount and filesystem
idmappings as they are two distinct types and require distinct helpers that
cannot be used interchangeably. We are now also able to extend struct mnt_idmap
as we see fit.

Acked-by: Dave Chinner &lt;dchinner@redhat.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Christian Brauner (Microsoft) &lt;brauner@kernel.org&gt;
</content>
</entry>
</feed>
