linux-stable/fs/ext2
Linus Torvalds bf4e7080ae fix directory locking scheme on rename
broken in 6.5; we really can't lock two unrelated directories
 without holding ->s_vfs_rename_mutex first and in case of
 same-parent rename of a subdirectory 6.5 ends up doing just
 that.
 
 Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQQqUNBr3gm4hGXdBJlZ7Krx/gZQ6wUCZZ+lyQAKCRBZ7Krx/gZQ
 60MWAP94hTqeMIpjhsUIkrTnylrIFaiw4UCWFJzIRG1QQYKqCgD/XUaWI9np7dL6
 0wR/j4CQSdJjiEFKUFE2pD3QoSuJYAQ=
 =+x0+
 -----END PGP SIGNATURE-----

Merge tag 'pull-rename' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs

Pull rename updates from Al Viro:
 "Fix directory locking scheme on rename

  This was broken in 6.5; we really can't lock two unrelated directories
  without holding ->s_vfs_rename_mutex first and in case of same-parent
  rename of a subdirectory 6.5 ends up doing just that"

* tag 'pull-rename' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
  rename(): avoid a deadlock in the case of parents having no common ancestor
  kill lock_two_inodes()
  rename(): fix the locking of subdirectories
  f2fs: Avoid reading renamed directory if parent does not change
  ext4: don't access the source subdirectory content on same-directory rename
  ext2: Avoid reading renamed directory if parent does not change
  udf_rename(): only access the child content on cross-directory rename
  ocfs2: Avoid touching renamed directory if parent does not change
  reiserfs: Avoid touching renamed directory if parent does not change
2024-01-11 20:00:22 -08:00
..
acl.c ext2: convert to ctime accessor functions 2023-07-13 10:28:07 +02:00
acl.h fs: port ->set_acl() to pass mnt_idmap 2023-01-19 09:24:27 +01:00
balloc.c \n 2023-08-30 12:10:50 -07:00
dir.c \n 2023-11-02 08:19:51 -10:00
ext2.h ext2: Convert ext2_unlink() and ext2_rename() to use folios 2023-10-25 20:31:29 +02:00
file.c ext2: Fix ki_pos update for DIO buffered-io fallback case 2023-11-22 10:17:10 +01:00
ialloc.c ext2: convert to new timestamp accessors 2023-10-18 13:26:21 +02:00
inode.c fs: convert error_remove_page to error_remove_folio 2023-12-10 16:51:42 -08:00
ioctl.c ext2: convert to ctime accessor functions 2023-07-13 10:28:07 +02:00
Kconfig fs: add CONFIG_BUFFER_HEAD 2023-08-02 09:13:09 -06:00
Makefile ext2: Add direct-io trace points 2023-05-16 11:32:42 +02:00
namei.c ext2: Avoid reading renamed directory if parent does not change 2023-11-25 02:53:20 -05:00
super.c vfs-6.7.fsid 2023-11-07 12:11:26 -08:00
symlink.c ext2: code cleanup by removing ifdef macro surrounding 2020-05-22 15:11:00 +02:00
trace.c ext2: Add direct-io trace points 2023-05-16 11:32:42 +02:00
trace.h ext2: Add direct-io trace points 2023-05-16 11:32:42 +02:00
xattr.c ext2: move ext2_xattr_handlers and ext2_xattr_handler_map to .rodata 2023-10-09 16:24:18 +02:00
xattr.h ext2: move ext2_xattr_handlers and ext2_xattr_handler_map to .rodata 2023-10-09 16:24:18 +02:00
xattr_security.c fs: port xattr to mnt_idmap 2023-01-19 09:24:28 +01:00
xattr_trusted.c fs: port xattr to mnt_idmap 2023-01-19 09:24:28 +01:00
xattr_user.c fs: port xattr to mnt_idmap 2023-01-19 09:24:28 +01:00