mirror of
				https://git.proxmox.com/git/mirror_zfs.git
				synced 2025-10-26 18:05:04 +03:00 
			
		
		
		
	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 <mmacy@FreeBSD.org>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Mateusz Guzik <mjguzik@gmail.com>
Closes #11115
			
			
This commit is contained in:
		
							parent
							
								
									082ff328f2
								
							
						
					
					
						commit
						973ba682f5
					
				| @ -620,7 +620,6 @@ zfs_znode_alloc(zfsvfs_t *zfsvfs, dmu_buf_t *db, int blksz, | ||||
| 	mutex_enter(&zfsvfs->z_znodes_lock); | ||||
| 	list_insert_tail(&zfsvfs->z_all_znodes, zp); | ||||
| 	zfsvfs->z_nr_znodes++; | ||||
| 	membar_producer(); | ||||
| 	mutex_exit(&zfsvfs->z_znodes_lock); | ||||
| 
 | ||||
| 	unlock_new_inode(ip); | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Mateusz Guzik
						Mateusz Guzik