summaryrefslogtreecommitdiff
path: root/rust/kernel/alloc/kvec/errors.rs
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2026-05-12 03:19:41 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2026-06-08 14:53:09 -0400
commit1a29e25799bcd7c3b2285f46e2c630b62d969b25 (patch)
treedc869c64fffec14c3c6c54e48278f811b55c563c /rust/kernel/alloc/kvec/errors.rs
parentabe91a2aa9c4a704e290e0e164228ff20a123c0a (diff)
configfs: dentry refcount needs to be pinned only once
currently we have a weird situation where * symlinks and roots of subtrees created by mkdir are pinned once * subdirectories of subtrees created by mkdir are pinned twice * roots of subtrees created by register_{group,subsystem} are pinned twice. It makes things harder to follow for no good reason. The goal is to encapsulate the unbalanced dget/dput into d_{make,discard}_persisitent() and, preferably, allow a use of simple_recursive_removal() or analogue thereof. So let's regularize that and pin things only once. create_default_group() and configfs_register_subsystem() don't need to keep their reference around on success - configfs_create_dir() has pinned the sucker already. So we can drop the reference passed to configfs_create_dir() (via configfs_attach_group(), etc.) both on success and on failure. On the removal side we no longer have the double references, so we need an explicit dget() to compensate. Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'rust/kernel/alloc/kvec/errors.rs')
0 files changed, 0 insertions, 0 deletions