/Linux-v6.6/fs/ceph/ |
D | io.c | 24 lockdep_assert_held_write(&inode->i_rwsem); in ceph_block_o_direct() 56 down_read(&inode->i_rwsem); in ceph_start_io_read() 59 up_read(&inode->i_rwsem); in ceph_start_io_read() 61 down_write(&inode->i_rwsem); in ceph_start_io_read() 63 downgrade_write(&inode->i_rwsem); in ceph_start_io_read() 76 up_read(&inode->i_rwsem); in ceph_end_io_read() 89 down_write(&inode->i_rwsem); in ceph_start_io_write() 103 up_write(&inode->i_rwsem); in ceph_end_io_write() 109 lockdep_assert_held_write(&inode->i_rwsem); in ceph_block_buffered() 142 down_read(&inode->i_rwsem); in ceph_start_io_direct() [all …]
|
/Linux-v6.6/fs/nfs/ |
D | io.c | 47 down_read(&inode->i_rwsem); in nfs_start_io_read() 50 up_read(&inode->i_rwsem); in nfs_start_io_read() 52 down_write(&inode->i_rwsem); in nfs_start_io_read() 54 downgrade_write(&inode->i_rwsem); in nfs_start_io_read() 67 up_read(&inode->i_rwsem); in nfs_end_io_read() 80 down_write(&inode->i_rwsem); in nfs_start_io_write() 94 up_write(&inode->i_rwsem); in nfs_end_io_write() 127 down_read(&inode->i_rwsem); in nfs_start_io_direct() 130 up_read(&inode->i_rwsem); in nfs_start_io_direct() 132 down_write(&inode->i_rwsem); in nfs_start_io_direct() [all …]
|
/Linux-v6.6/fs/orangefs/ |
D | file.c | 329 down_read(&file_inode(iocb->ki_filp)->i_rwsem); in orangefs_file_read_iter() 336 up_read(&file_inode(iocb->ki_filp)->i_rwsem); in orangefs_file_read_iter() 349 down_read(&inode->i_rwsem); in orangefs_file_splice_read() 356 up_read(&inode->i_rwsem); in orangefs_file_splice_read()
|
/Linux-v6.6/fs/ |
D | readdir.c | 55 up_read(&inode->i_rwsem); in wrap_directory_iterator() 56 down_write(&inode->i_rwsem); in wrap_directory_iterator() 69 downgrade_write(&inode->i_rwsem); in wrap_directory_iterator() 99 res = down_read_killable(&inode->i_rwsem); in iterate_dir()
|
D | inode.c | 198 init_rwsem(&inode->i_rwsem); in inode_init_always() 199 lockdep_set_class(&inode->i_rwsem, &sb->s_type->i_mutex_key); in inode_init_always() 1044 if (lockdep_match_class(&inode->i_rwsem, &type->i_mutex_key)) { in lockdep_annotate_inode_mutex_key() 1049 init_rwsem(&inode->i_rwsem); in lockdep_annotate_inode_mutex_key() 1050 lockdep_set_class(&inode->i_rwsem, in lockdep_annotate_inode_mutex_key()
|
D | dax.c | 1564 lockdep_assert_held_write(&iomi.inode->i_rwsem); in dax_iomap_rw() 1567 lockdep_assert_held(&iomi.inode->i_rwsem); in dax_iomap_rw()
|
D | libfs.c | 474 lockdep_assert_held(&d_inode(dir)->i_rwsem); in offset_readdir()
|
/Linux-v6.6/Documentation/filesystems/ |
D | directory-locking.rst | 7 kinds of locks - per-inode (->i_rwsem) and per-filesystem 10 When taking the i_rwsem on multiple non-directory objects, we 59 All ->i_rwsem are taken exclusive. Again, we might get away with locking 96 Thus all processes are blocked on ->i_rwsem.
|
D | locking.rst | 94 ops i_rwsem(inode) 123 Additionally, ->rmdir(), ->unlink() and ->rename() have ->i_rwsem 148 ops i_rwsem(inode) 273 ops folio locked i_rwsem invalidate_lock 562 ->iterate_shared() is called with i_rwsem held for reading, and with the 597 blocking changes through write(2) and similar operations inode->i_rwsem can be
|
D | path-lookup.rst | 246 inode->i_rwsem 249 ``i_rwsem`` is a read/write semaphore that serializes all changes to a particular 256 This has a complementary role to that of ``d_lock``: ``i_rwsem`` on a 259 dcache hold ``i_rwsem`` on the relevant directory inode and briefly take 262 memory pressure. This uses ``d_lock``, but ``i_rwsem`` plays no role. 268 falls back to ``lookup_slow()`` which takes a shared lock on ``i_rwsem``, checks again that 274 sometimes need to take an exclusive lock on ``i_rwsem`` before performing the last lookup so 276 to take, or not take, ``i_rwsem`` is one of the 280 name that is not yet in the dcache - the shared lock on ``i_rwsem`` will 287 ``i_rwsem``, a thread must call ``d_alloc_parallel()``. This allocates a [all …]
|
D | gfs2-glocks.rst | 115 1. i_rwsem (if required)
|
/Linux-v6.6/fs/xfs/scrub/ |
D | xfile.c | 95 lockdep_set_class(&inode->i_rwsem, &xfile_i_mutex_key); in xfile_create() 115 lockdep_set_class(&inode->i_rwsem, &inode->i_sb->s_type->i_mutex_key); in xfile_destroy()
|
/Linux-v6.6/fs/xfs/ |
D | xfs_inode.c | 195 down_write_nested(&VFS_I(ip)->i_rwsem, in xfs_ilock() 198 down_read_nested(&VFS_I(ip)->i_rwsem, in xfs_ilock() 238 if (!down_write_trylock(&VFS_I(ip)->i_rwsem)) in xfs_ilock_nowait() 241 if (!down_read_trylock(&VFS_I(ip)->i_rwsem)) in xfs_ilock_nowait() 269 up_write(&VFS_I(ip)->i_rwsem); in xfs_ilock_nowait() 271 up_read(&VFS_I(ip)->i_rwsem); in xfs_ilock_nowait() 296 up_write(&VFS_I(ip)->i_rwsem); in xfs_iunlock() 298 up_read(&VFS_I(ip)->i_rwsem); in xfs_iunlock() 331 downgrade_write(&VFS_I(ip)->i_rwsem); in xfs_ilock_demote() 374 return __xfs_rwsem_islocked(&VFS_I(ip)->i_rwsem, in xfs_isilocked()
|
D | xfs_iops.c | 1286 lockdep_set_class(&inode->i_rwsem, in xfs_setup_inode()
|
D | xfs_icache.c | 359 ASSERT(!rwsem_is_locked(&inode->i_rwsem)); in xfs_iget_recycle()
|
D | xfs_super.c | 664 ASSERT(!rwsem_is_locked(&inode->i_rwsem)); in xfs_fs_destroy_inode()
|
/Linux-v6.6/include/linux/ |
D | fs.h | 689 struct rw_semaphore i_rwsem; member 802 down_write(&inode->i_rwsem); in inode_lock() 807 up_write(&inode->i_rwsem); in inode_unlock() 812 down_read(&inode->i_rwsem); in inode_lock_shared() 817 up_read(&inode->i_rwsem); in inode_unlock_shared() 822 return down_write_trylock(&inode->i_rwsem); in inode_trylock() 827 return down_read_trylock(&inode->i_rwsem); in inode_trylock_shared() 832 return rwsem_is_locked(&inode->i_rwsem); in inode_is_locked() 837 down_write_nested(&inode->i_rwsem, subclass); in inode_lock_nested() 842 down_read_nested(&inode->i_rwsem, subclass); in inode_lock_shared_nested()
|
/Linux-v6.6/fs/configfs/ |
D | inode.c | 134 lockdep_set_class(&inode->i_rwsem, in configfs_set_inode_lock_class()
|
/Linux-v6.6/lib/ |
D | test_lockup.c | 548 lock_rwsem_ptr = (unsigned long)&test_inode->i_rwsem; in test_lockup_init()
|
/Linux-v6.6/fs/overlayfs/ |
D | inode.c | 955 lockdep_set_class(&inode->i_rwsem, &ovl_i_mutex_dir_key[depth]); in ovl_lockdep_annotate_inode_mutex_key() 957 lockdep_set_class(&inode->i_rwsem, &ovl_i_mutex_key[depth]); in ovl_lockdep_annotate_inode_mutex_key()
|
D | readdir.c | 276 err = down_write_killable(&dir->d_inode->i_rwsem); in ovl_check_whiteouts()
|
/Linux-v6.6/fs/ocfs2/ |
D | inode.c | 245 lockdep_set_class(&inode->i_rwsem, in ocfs2_init_locked_inode()
|
/Linux-v6.6/fs/gfs2/ |
D | ops_fstype.c | 910 lockdep_set_class(&sdp->sd_quota_inode->i_rwsem, in init_inodes()
|
/Linux-v6.6/fs/btrfs/ |
D | delayed-inode.c | 1742 downgrade_write(&inode->i_rwsem); in btrfs_readdir_put_delayed_items()
|
D | ioctl.c | 967 error = down_write_killable_nested(&dir->i_rwsem, I_MUTEX_PARENT); in btrfs_mksubvol() 2478 err = down_write_killable_nested(&dir->i_rwsem, I_MUTEX_PARENT); in btrfs_ioctl_snap_destroy()
|