tmpfs: drop useless parent locking from tmpfs_dir_getdotdotdent

The id field is immutable until the node gets freed.
This commit is contained in:
Mateusz Guzik 2021-05-29 17:38:21 +02:00
parent 3cf75ca220
commit 7fbeaf33b8

View File

@ -1436,10 +1436,7 @@ tmpfs_dir_getdotdotdent(struct tmpfs_mount *tm, struct tmpfs_node *node,
if (parent == NULL)
return (ENOENT);
TMPFS_NODE_LOCK(parent);
dent.d_fileno = parent->tn_id;
TMPFS_NODE_UNLOCK(parent);
dent.d_off = next;
dent.d_type = DT_DIR;
dent.d_namlen = 2;