linux/fs/ext4
Linus Torvalds 00b04f4495 vfs-7.4-rc1.idmap
Please consider pulling these changes from the signed vfs-7.4-rc1.idmap tag.
 
 Thanks!
 Christian
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYKAB0WIQRAhzRXHqcMeLMyaSiRxhvAZXjcogUCatHrlgAKCRCRxhvAZXjc
 opFuAPwLL5l3D3GSRyD+SyOjKYThylgowvH9c2BcLWbSAIO6yQD9F05GX+rrcbUq
 9ijolxAaQZYpEWsemZIIHx6BBwdDBA4=
 =IH8Z
 -----END PGP SIGNATURE-----

Merge tag 'vfs-7.4-rc1.idmap' of git://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs

Pull vfs idmap constification from Christian Brauner:
 "This makes struct mnt_idmap const throughout the tree.

  A mount's idmapping is immutable. The only thing modified after
  alloc_mnt_idmap() is the reference count and that is hidden behind
  mnt_idmap_get() and mnt_idmap_put(). Everything else only reads from
  it. That is the same model struct cred uses and the idmapping is
  sensitive enough to deserve it.

  The conversion goes bottom up through the vfs{g,u}id and fs{g,u}id
  helpers, the privilege checks, acl, xattr and quota and then every
  inode operation that takes an idmap, so ->permission(), ->getattr(),
  ->setattr(), ->create(), ->mkdir(), ->mknod(), ->symlink(),
  ->rename(), ->tmpfile(), ->get_acl(), ->set_acl() and ->fileattr_set()
  with their implementations in every filesystem, plus the LSM hooks.

  struct vfsmount, struct mount_kattr and struct kstatmount store a
  const pointer and nop_mnt_idmap and invalid_mnt_idmap live in rodata,
  so anything that tries to modify them faults instead of silently
  corrupting the initial idmapping"

* tag 'vfs-7.4-rc1.idmap' of git://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs: (27 commits)
  fs: make nop_mnt_idmap and invalid_mnt_idmap const
  fs: port mnt_idmap() and file_mnt_idmap() to const mnt_idmap
  fs: port vfs_*() helpers to const mnt_idmap
  fs: port ->setattr() to pass const mnt_idmap
  fs: port ->getattr() to pass const mnt_idmap
  fs: port ->create() to pass const mnt_idmap
  fs: port ->symlink() to pass const mnt_idmap
  fs: port ->mkdir() to pass const mnt_idmap
  fs: port ->rename() to pass const mnt_idmap
  fs: port ->mknod() to pass const mnt_idmap
  fs: port ->tmpfile() to pass const mnt_idmap
  fs: port ->get_acl() to pass const mnt_idmap
  fs: port ->set_acl() to pass const mnt_idmap
  fs: port ->fileattr_set() to pass const mnt_idmap
  fs: port xattr to const mnt_idmap
  fs: port ->permission() to pass const mnt_idmap
  fs: port acl to const mnt_idmap
  fs: port inode_init_owner() to const mnt_idmap
  fs: port inode_owner_or_capable() to const mnt_idmap
  fs: port privilege checking helpers to const mnt_idmap
  ...
2026-10-19 17:57:49 -10:00
..
.kunitconfig
acl.c fs: port ->set_acl() to pass const mnt_idmap 2026-09-23 09:19:49 +02:00
acl.h fs: port ->set_acl() to pass const mnt_idmap 2026-09-23 09:19:49 +02:00
balloc.c ext4: guard against NULL s_group_info in ext4_get_group_info 2026-08-06 10:34:27 -04:00
bitmap.c
block_validity.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
crypto.c Various ext4 updates for 7.3-rc1, including: 2026-08-20 13:17:11 -07:00
dir.c ext4: validate readdir offset before accessing dirent 2026-07-22 11:49:33 -04:00
ext4_extents.h ext4: fix extents-test.c is not compiled when EXT4_KUNIT_TESTS=M 2026-03-27 23:36:06 -04:00
ext4_jbd2.c ext4: check for a metadata write error with buffer_write_io_error() 2026-09-10 09:27:25 +02:00
ext4_jbd2.h ext4: enable scoped NOFS when starting a handle in nojournal mode 2026-07-22 23:47:06 -04:00
ext4.h vfs-7.4-rc1.idmap 2026-10-19 17:57:49 -10:00
extents_status.c ext4: free the sbi after a grace period 2026-10-14 22:08:02 +02:00
extents_status.h ext4: free the sbi after a grace period 2026-10-14 22:08:02 +02:00
extents-test.c ext4: free the sbi after a grace period 2026-10-14 22:08:02 +02:00
extents.c ext4: free the sbi after a grace period 2026-10-14 22:08:02 +02:00
fast_commit.c treewide: refresh kmalloc_obj() conversions 2026-09-04 21:37:00 -07:00
fast_commit.h ext4: mark move extents fast-commit ineligible 2026-01-19 19:26:35 -05:00
file.c Various ext4 updates for 7.3-rc1, including: 2026-08-20 13:17:11 -07:00
fsmap.c treewide: Replace kmalloc with kmalloc_obj for non-scalar types 2026-02-21 01:02:28 -08:00
fsmap.h
fsync.c ext4: Fix data integrity writeout issues in nojournal mode 2026-07-27 16:25:33 +02:00
hash-test.c ext4: add Kunit coverage for directory hash computation 2026-06-03 10:30:15 -04:00
hash.c ext4: improve str2hashbuf by processing 4-byte chunks and removing function pointers 2026-06-03 10:30:15 -04:00
ialloc.c fs: port inode_init_owner() to const mnt_idmap 2026-09-23 09:19:48 +02:00
indirect.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
inline.c ext4: cleanup unused CONVERT_INLINE_DATA flag 2026-07-22 11:49:33 -04:00
inode-test.c
inode.c vfs-7.4-rc1.idmap 2026-10-19 17:57:49 -10:00
ioctl.c fs: port mnt_idmap() and file_mnt_idmap() to const mnt_idmap 2026-09-23 09:19:51 +02:00
Kconfig ext4: remove obsolete EXT3 config options 2025-09-25 14:47:05 -04:00
Makefile ext4: add Kunit coverage for directory hash computation 2026-06-03 10:30:15 -04:00
mballoc-test.c ext4: use anonymous devices for KUnit test superblocks 2026-06-29 10:31:52 +02:00
mballoc.c ext4: get ext4_group_desc in ext4_mb_prefetch only when necessary 2026-07-21 11:26:39 -04:00
mballoc.h ext4: fix mballoc-test.c is not compiled when EXT4_KUNIT_TESTS=M 2026-03-27 23:36:02 -04:00
migrate.c ext4: fix circular lock dependency in ext4_ext_migrate 2026-07-21 11:26:39 -04:00
mmp.c ext4: check for a metadata write error with buffer_write_io_error() 2026-09-10 09:27:25 +02:00
move_extent.c Various clean ups and bug fixes in ext4 for 7.1: 2026-04-17 17:08:31 -07:00
namei.c fs: port ->create() to pass const mnt_idmap 2026-09-23 09:19:51 +02:00
orphan.c ext4: fix spurious message about orphan cleanup on RO fs 2026-08-06 10:24:31 -04:00
page-io.c ext4: Make ext4_bio_write_folio() return void 2026-07-20 10:39:25 -07:00
readpage.c ext4: Further de-generalize the bio postprocessing code 2026-07-20 10:39:25 -07:00
resize.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
super.c ext4: free the sbi after a grace period 2026-10-14 22:08:02 +02:00
symlink.c fs: port ->getattr() to pass const mnt_idmap 2026-09-23 09:19:51 +02:00
sysfs.c ext4: fix use-after-free in update_super_work when racing with umount 2026-03-27 23:37:39 -04:00
truncate.h
verity.c fsverity updates for 7.0 2026-02-12 10:41:34 -08:00
xattr_hurd.c fs: port xattr to const mnt_idmap 2026-09-23 09:19:49 +02:00
xattr_security.c fs: port xattr to const mnt_idmap 2026-09-23 09:19:49 +02:00
xattr_trusted.c fs: port xattr to const mnt_idmap 2026-09-23 09:19:49 +02:00
xattr_user.c fs: port xattr to const mnt_idmap 2026-09-23 09:19:49 +02:00
xattr.c ext4: stop retrying saturated xattr cache entries 2026-08-06 10:23:48 -04:00
xattr.h ext4: remove ea_inode_array mechanism in favor of ext4_put_ea_inode() 2026-07-22 12:27:43 -04:00