@@ -1755,6 +1755,16 @@ zfs_mkdir(znode_t *dzp, const char *dirname, vattr_t *vap, znode_t **zpp,
1755
1755
return (0 );
1756
1756
}
1757
1757
1758
+ #if __FreeBSD_version < 1300124
1759
+ static void
1760
+ cache_vop_rmdir (struct vnode * dvp , struct vnode * vp )
1761
+ {
1762
+
1763
+ cache_purge (dvp );
1764
+ cache_purge (vp );
1765
+ }
1766
+ #endif
1767
+
1758
1768
/*
1759
1769
* Remove a directory subdir entry. If the current working
1760
1770
* directory is the same as the subdir to be removed, the
@@ -1814,8 +1824,6 @@ zfs_rmdir_(vnode_t *dvp, vnode_t *vp, const char *name, cred_t *cr)
1814
1824
return (error );
1815
1825
}
1816
1826
1817
- cache_purge (dvp );
1818
-
1819
1827
error = zfs_link_destroy (dzp , name , zp , tx , ZEXISTS , NULL );
1820
1828
1821
1829
if (error == 0 ) {
@@ -1826,7 +1834,7 @@ zfs_rmdir_(vnode_t *dvp, vnode_t *vp, const char *name, cred_t *cr)
1826
1834
1827
1835
dmu_tx_commit (tx );
1828
1836
1829
- cache_purge ( vp );
1837
+ cache_vop_rmdir ( dvp , vp );
1830
1838
out :
1831
1839
if (zfsvfs -> z_os -> os_sync == ZFS_SYNC_ALWAYS )
1832
1840
zil_commit (zilog , 0 );
@@ -3362,9 +3370,9 @@ zfs_rename_check(znode_t *szp, znode_t *sdzp, znode_t *tdzp)
3362
3370
return (error );
3363
3371
}
3364
3372
3365
- #if __FreeBSD_version < 1300110
3373
+ #if __FreeBSD_version < 1300124
3366
3374
static void
3367
- cache_rename (struct vnode * fdvp , struct vnode * fvp , struct vnode * tdvp ,
3375
+ cache_vop_rename (struct vnode * fdvp , struct vnode * fvp , struct vnode * tdvp ,
3368
3376
struct vnode * tvp , struct componentname * fcnp , struct componentname * tcnp )
3369
3377
{
3370
3378
@@ -3633,7 +3641,7 @@ zfs_rename_(vnode_t *sdvp, vnode_t **svpp, struct componentname *scnp,
3633
3641
}
3634
3642
}
3635
3643
if (error == 0 ) {
3636
- cache_rename (sdvp , * svpp , tdvp , * tvpp , scnp , tcnp );
3644
+ cache_vop_rename (sdvp , * svpp , tdvp , * tvpp , scnp , tcnp );
3637
3645
}
3638
3646
}
3639
3647
0 commit comments