Skip to content

Commit 973ba68

Browse files
authored
Linux: g/c leftover fence in zfs_znode_alloc
The port removed provisions for zfs_znode_move but the cleanup missed this bit. To quote the original: [snip] list_insert_tail(&zfsvfs->z_all_znodes, zp); membar_producer(); /* * Everything else must be valid before assigning z_zfsvfs makes the * znode eligible for zfs_znode_move(). */ zp->z_zfsvfs = zfsvfs; [/snip] In the current code it is immediately followed by unlock which issues the same fence, thus plays no role in correctness. Reviewed-by: Matt Macy <[email protected]> Reviewed-by: Brian Behlendorf <[email protected]> Signed-off-by: Mateusz Guzik <[email protected]> Closes #11115
1 parent 082ff32 commit 973ba68

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

module/os/linux/zfs/zfs_znode.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -620,7 +620,6 @@ zfs_znode_alloc(zfsvfs_t *zfsvfs, dmu_buf_t *db, int blksz,
620620
mutex_enter(&zfsvfs->z_znodes_lock);
621621
list_insert_tail(&zfsvfs->z_all_znodes, zp);
622622
zfsvfs->z_nr_znodes++;
623-
membar_producer();
624623
mutex_exit(&zfsvfs->z_znodes_lock);
625624

626625
unlock_new_inode(ip);

0 commit comments

Comments
 (0)