X-Git-Url: https://git.camperquake.de/gitweb.cgi?a=blobdiff_plain;ds=sidebyside;f=module%2Fzfs%2Fzfs_vfsops.c;h=2575638870528545e42a78d6fab2dffb154d0672;hb=b312979252c5b566d2f59febcda67f309637e18c;hp=8a82d9d4b226ecbe4514545b5f95145977a04cf0;hpb=e30c0ada6d0174e044b96fbedf5946c3be66e956;p=zfs.git diff --git a/module/zfs/zfs_vfsops.c b/module/zfs/zfs_vfsops.c index 8a82d9d..2575638 100644 --- a/module/zfs/zfs_vfsops.c +++ b/module/zfs/zfs_vfsops.c @@ -1092,6 +1092,12 @@ zfsvfs_teardown(zfs_sb_t *zsb, boolean_t unmounting) } /* + * Drain the iput_taskq to ensure all active references to the + * zfs_sb_t have been handled only then can it be safely destroyed. + */ + taskq_wait(dsl_pool_iput_taskq(dmu_objset_pool(zsb->z_os))); + + /* * Close the zil. NB: Can't close the zil while zfs_inactive * threads are blocked as zil_close can call zfs_inactive. */ @@ -1206,9 +1212,7 @@ zfs_domount(struct super_block *sb, void *data, int silent) /* Set callback operations for the file system. */ sb->s_op = &zpl_super_operations; sb->s_xattr = zpl_xattr_handlers; -#ifdef HAVE_EXPORTS - sb->s_export_op = &zpl_export_operations; -#endif /* HAVE_EXPORTS */ + sb->s_export_op = &zpl_export_operations; /* Set features for file system. */ zfs_set_fuid_feature(zsb);