Eliminate Linux specific inode usage from common code

Change many of the znops routines to take a znode rather
than an inode so that zfs_replay code can be largely shared
and in the future the much of the znops code may be shared.

Reviewed-by: Jorgen Lundman <lundman@lundman.net>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Matt Macy <mmacy@FreeBSD.org>
Closes #9708
This commit is contained in:
Matthew Macy
2019-12-11 11:53:57 -08:00
committed by Brian Behlendorf
parent f0bf435176
commit 657ce25357
18 changed files with 346 additions and 333 deletions
+4 -4
View File
@@ -220,7 +220,7 @@ dsl_pool_open_impl(spa_t *spa, uint64_t txg)
mutex_init(&dp->dp_lock, NULL, MUTEX_DEFAULT, NULL);
cv_init(&dp->dp_spaceavail_cv, NULL, CV_DEFAULT, NULL);
dp->dp_iput_taskq = taskq_create("z_iput", max_ncpus, defclsyspri,
dp->dp_zrele_taskq = taskq_create("z_zrele", max_ncpus, defclsyspri,
max_ncpus * 8, INT_MAX, TASKQ_PREPOPULATE | TASKQ_DYNAMIC);
dp->dp_unlinked_drain_taskq = taskq_create("z_unlinked_drain",
max_ncpus, defclsyspri, max_ncpus, INT_MAX,
@@ -416,7 +416,7 @@ dsl_pool_close(dsl_pool_t *dp)
mutex_destroy(&dp->dp_lock);
cv_destroy(&dp->dp_spaceavail_cv);
taskq_destroy(dp->dp_unlinked_drain_taskq);
taskq_destroy(dp->dp_iput_taskq);
taskq_destroy(dp->dp_zrele_taskq);
if (dp->dp_blkstats != NULL) {
mutex_destroy(&dp->dp_blkstats->zab_lock);
vmem_free(dp->dp_blkstats, sizeof (zfs_all_blkstats_t));
@@ -1102,9 +1102,9 @@ dsl_pool_create_origin(dsl_pool_t *dp, dmu_tx_t *tx)
}
taskq_t *
dsl_pool_iput_taskq(dsl_pool_t *dp)
dsl_pool_zrele_taskq(dsl_pool_t *dp)
{
return (dp->dp_iput_taskq);
return (dp->dp_zrele_taskq);
}
taskq_t *