• Home
  • Raw
  • Download

Lines Matching +full:pin +full:- +full:pud

5 The text below describes the locking rules for VFS-related methods.
6 It is (believed to be) up-to-date. *Please*, if you change anything in
7 prototypes or locking protocols - update this file. And update the relevant
10 Don't turn it into log - maintainers of out-of-the-tree code are supposed to
37 ops rename_lock ->d_lock may block rcu-walk
39 d_revalidate: no no yes (ref-walk) maybe
50 d_manage: no no yes (ref-walk) maybe
108 permission: no (may not block if called in rcu-walk mode)
123 Additionally, ->rmdir(), ->unlink() and ->rename() have ->i_rwsem
125 cross-directory ->rename() has (per-superblock) ->s_vfs_rename_sem.
126 ->unlink() and ->rename() have ->i_rwsem exclusive on all non-directories
128 ->rename() has ->i_rwsem exclusive on any subdirectory that changes parent.
130 See Documentation/filesystems/directory-locking.rst for more detailed discussion
192 drop_inode: !!!inode->i_lock!!!
206 ->statfs() has s_umount (shared) when called by ustat(2) (native or
207 compat), but that's an accident of bad API; s_umount is used to pin
210 doesn't hold it when calling ->statfs() - superblock is pinned down
213 ->quota_read() and ->quota_write() functions are both guaranteed to
237 ->mount() returns ERR_PTR or the root dentry; its superblock should be locked
240 ->kill_sb() takes a write-locked superblock, does all shutdown work on it,
299 ->write_begin(), ->write_end() and ->read_folio() may be called from
302 ->read_folio() unlocks the folio, either synchronously or via I/O
305 ->readahead() unlocks the folios that I/O is attempted on like ->read_folio().
307 ->writepage() is used for two purposes: for "memory cleansing" and for
311 If writepage is called for sync (wbc->sync_mode != WBC_SYNC_NONE) then
313 blocking on in-progress I/O.
318 currently-in-progress I/O.
321 would need to block against in-progress I/O to be able to start new I/O
327 in-progress I/O and then start new I/O.
330 caller, unless ->writepage() returns special WRITEPAGE_ACTIVATE
332 currently, and VM should stop calling ->writepage() on this page for some
352 radix tree. This incoherency can lead to all sorts of hard-to-debug problems
355 ->writepages() is used for periodic writeback and for syscall-initiated
363 mapping->io_pages.
365 ->dirty_folio() is called from various places in the kernel when
371 ->bmap() is currently used by legacy ioctl() (FIBMAP) provided by some
375 ->invalidate_folio() is called when the filesystem must attempt to drop
379 path (and thus calling into ->invalidate_folio) to block races between page
382 ->release_folio() is called when the MM wants to make a change to the
390 the folio. If a filesystem does not provide a ->release_folio method,
394 ->free_folio() is called when the kernel has dropped the folio
397 ->launder_folio() may be called prior to releasing a folio if
403 ->swap_activate() will be called to prepare the given file for swap. It
408 ->swap_rw(), it should set SWP_FS_OPS, otherwise IO will be submitted
409 directly to the block device ``sis->bdev``.
411 ->swap_deactivate() will be called in the sys_swapoff()
412 path after ->swap_activate() returned success.
414 ->swap_rw will be called for swap IO if SWP_FS_OPS was set by ->swap_activate().
428 ops inode->i_lock may block
435 ->fl_release_private for flock or POSIX locks is currently allowed
557 ->llseek() locking has moved from llseek to the individual llseek
559 need to acquire and release the appropriate locks in your ->llseek().
562 Note: this does not protect the file->f_pos against concurrent modifications
565 ->iterate_shared() is called with i_rwsem held for reading, and with the
568 ->fasync() is responsible for maintaining the FASYNC bit in filp->f_flags.
573 ->readdir() and ->ioctl() on directories must be changed. Ideally we would
574 move ->readdir() to inode_operations and use a separate method for directory
575 ->ioctl() or kill the latter completely. One of the problems is that for
576 anything that resembles union-mount we won't have a struct file for all
579 ->read on directories probably must go away - we should just enforce -EISDIR
582 ->setlease operations should call generic_setlease() before or after setting
586 ->fallocate implementation must be really careful to maintain page cache
591 view of file offset -> disk block mapping. Until this update is finished, the
592 filesystem needs to block page faults and reads from reloading now-stale page
593 cache contents from the disk. Since VFS acquires mapping->invalidate_lock in
598 ->copy_file_range and ->remap_file_range implementations need to serialize
600 blocking changes through write(2) and similar operations inode->i_rwsem can be
602 operation, the filesystem must take mapping->invalidate_lock to coordinate
603 with ->page_mkwrite.
627 mark_dirty: no -
631 FS recursion means calling ->quota_read() and ->quota_write() from superblock
658 huge_fault: maybe-read
659 map_pages: maybe-read
665 ->fault() is called when a previously not present pte is about to be faulted
673 ->huge_fault() is called when there is no PUD or PMD entry present. This
674 gives the filesystem the opportunity to install a PUD or PMD sized page.
675 Filesystems can also use the ->fault method to return a PMD sized page,
677 filesystems should not call filemap_fault() from ->huge_fault().
680 ->map_pages() is called when VM asks to map easy accessible pages.
682 till "end_pgoff". ->map_pages() is called with the RCU lock held and must
689 ->page_mkwrite() is called when a previously read-only pte is about to become
691 truncate/invalidate races or races with operations such as ->remap_file_range
692 or ->copy_file_range, and then return with the page locked. Usually
693 mapping->invalidate_lock is suitable for proper serialization. If the page has
694 been truncated, the filesystem should not look up a new page like the ->fault()
698 ->pfn_mkwrite() is the same as page_mkwrite but when the pte is
699 VM_PFNMAP or VM_MIXEDMAP with a page-less entry. Expected return is
701 after this call is to make the pte read-write, unless pfn_mkwrite returns
704 ->access() is called when get_user_pages() fails in
709 --------------------------------------------------------------------------------
714 - at least put it here)