diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2023-10-29 18:38:27 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2023-11-25 02:33:42 -0500 |
commit | ee0c82503dcd0d14cc1ad53da18d32a04f612c4c (patch) | |
tree | 2d49579d0132aa562488be0fceffc940a3dcaf15 /block | |
parent | e9d130d05077e71b1224ad96e419f5f5512b8574 (diff) |
__dentry_kill(): get consistent rules for victim's refcount
Currently we call it with refcount equal to 1 when called from
dentry_kill(); all other callers have it equal to 0.
Make it always be called with zero refcount; on this step we
just decrement it before the calls in dentry_kill(). That is
safe, since all places that care about the value of refcount
either do that under ->d_lock or hold a reference to dentry
in question. Either is sufficient to prevent observing a
dentry immediately prior to __dentry_kill() getting called
from dentry_kill().
Reviewed-by: Christian Brauner <brauner@kernel.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'block')
0 files changed, 0 insertions, 0 deletions