]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
Merge tag 'vfs-7.3-rc1.ovl' of git://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs
authorLinus Torvalds <torvalds@linux-foundation.org>
Mon, 17 Aug 2026 20:38:36 +0000 (13:38 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Mon, 17 Aug 2026 20:38:36 +0000 (13:38 -0700)
Pull overlayfs updates from Christian Brauner:
 "This lets the merged overlayfs mount itself be idmapped through
  mount_setattr(MOUNT_ATTR_IDMAP), in addition to the already supported
  idmapped lower and upper layers. The same overlay tree can then be
  exposed under a different ownership view.

  Overlayfs already normalizes every underlying id through the relevant
  layer idmap when ovl_copyattr() copies attributes into the overlay
  inode. So the overlay inode's i_uid and i_gid are overlay-final ids.

  The overlay mount idmap composes on top of that and is applied at the
  overlay-inode boundary only while the underlying layers keep being
  accessed with the mounter's credentials through their own (possibly
  idmapped) mounts.

  So this only changes how the caller sees the overlay inode and never
  widens the mounter's access to the layers. The second,
  mounter-credential check in ovl_permission() against the real inode
  stays on the layer idmap.

  Most paths need no change because the VFS applies the mount idmap to
  the overlay inode before overlayfs runs or after it returns at the
  syscall boundary. Overlayfs only has to change where it bypasses the
  generic path.

  This also included is a fix for a double end_creating() on the
  overlayfs casefold-mismatch path"

* tag 'vfs-7.3-rc1.ovl' of git://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs:
  ovl: fix double end_creating() on the casefold-mismatch path
  ovl: document security.capability idmapping on the xattr forward paths
  selftests/filesystems/overlayfs: test idmapped overlay mounts
  selftests/filesystems/overlayfs: fix set_layers_via_fds link error
  docs: document idmapped overlay mounts
  ovl: allow idmapping overlay mounts
  ovl: handle idmapped mounts in ovl_set_acl()
  ovl: handle idmapped mounts in ovl_getattr()
  ovl: handle idmapped mounts in ovl_setattr()
  ovl: handle idmapped mounts in ovl_permission()
  ovl: handle idmapped mounts in ovl_create_object() and ovl_tmpfile()

1  2 
fs/overlayfs/dir.c
fs/overlayfs/inode.c
fs/overlayfs/super.c
fs/overlayfs/xattrs.c

index 88bcf98d287d1e2fd4075be73af8b0ff9237ecf9,3cd8194cbb1df137e6e302653e8d258e457405b5..7beb0af26498470137b8d261a74266a62948ded1
@@@ -732,9 -731,9 +731,9 @@@ out
  }
  
  static int ovl_create(struct mnt_idmap *idmap, struct inode *dir,
 -                    struct dentry *dentry, umode_t mode, bool excl)
 +                    struct dentry *dentry, umode_t mode)
  {
-       return ovl_create_object(dentry, (mode & 07777) | S_IFREG, 0, NULL);
+       return ovl_create_object(idmap, dentry, (mode & 07777) | S_IFREG, 0, NULL);
  }
  
  static struct dentry *ovl_mkdir(struct mnt_idmap *idmap, struct inode *dir,
Simple merge
Simple merge
Simple merge