]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
rpc_pipe: don't overdo directory locking
authorAl Viro <viro@zeniv.linux.org.uk>
Sat, 22 Mar 2025 23:39:40 +0000 (19:39 -0400)
committerAl Viro <viro@zeniv.linux.org.uk>
Thu, 3 Jul 2025 02:44:55 +0000 (22:44 -0400)
commit41a6b9e52b21544c334830bfe68fb78d6677caa0
tree7b9ea3db637a3e2eb27a01a759e6fe14f6ebfbd3
parent19a6314a997f6adde0c100ecf9224d1ab43c9603
rpc_pipe: don't overdo directory locking

Don't try to hold directories locked more than VFS requires;
lock just before getting a child to be made positive (using
simple_start_creating()) and unlock as soon as the child is
created.  There's no benefit in keeping the parent locked
while populating the child - it won't stop dcache lookups anyway.

Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
net/sunrpc/rpc_pipe.c