mirror_zfs/include/os/linux/zfs/sys
Rob Norris 15a6b982c5 linux/super: add tunable to request immediate reclaim of unused dentries
Traditionally, unused dentries would be cached in the dentry cache until
the associated entry is no longer on disk. The cached dentry continues
to hold an inode reference, causing the inode to be pinned (see previous
commit).

Here we implement the dentry op d_delete, which is roughly analogous to
the drop_inode superblock op, and add a zfs_delete_dentry tunable to
control its behaviour. By default it continues the traditional
behaviour, but when the tunable is enabled, we signal that an unused
dentry should be freed immediately, releasing its inode reference, and
so allowing that inode to be deleted if no longer in use.

Sponsored-by: Klara, Inc.
Sponsored-by: Fastmail Pty Ltd
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com>
Signed-off-by: Rob Norris <rob.norris@klarasystems.com>
Closes #17746
2025-09-17 16:34:14 -07:00
..
abd_impl_os.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
abd_os.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
policy.h cred: properly pass and test creds on other threads (#17273) 2025-04-29 16:27:48 -07:00
trace_acl.h Linux: sync: remove async/sync accounting 2025-08-06 09:54:30 -07:00
trace_arc.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
trace_common.h zio: rename io_reexecute as io_post; use it for the direct IO checksum error flag 2025-07-04 23:16:14 -04:00
trace_dbgmsg.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
trace_dbuf.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
trace_dmu.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
trace_dnode.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
trace_multilist.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
trace_rrwlock.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
trace_txg.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
trace_vdev.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
trace_zfs.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
trace_zil.h trace_zil.h: rename zcw_zio_error to zcw_error 2025-08-19 10:54:50 -04:00
trace_zio.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
trace_zrlock.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
zfs_bootenv_os.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
zfs_context_os.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
zfs_ctldir.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
zfs_dir.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
zfs_vfsops_os.h Add default user/group/project quota properties 2025-04-03 10:35:22 -07:00
zfs_vnops_os.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
zfs_znode_impl.h Define sops->free_inode() to prevent use-after-free during lookup 2025-07-18 08:45:13 -07:00
zpl.h linux/super: add tunable to request immediate reclaim of unused dentries 2025-09-17 16:34:14 -07:00