diff --git a/man/man4/zfs.4 b/man/man4/zfs.4 index dbddf1bf59..71a95c3bd8 100644 --- a/man/man4/zfs.4 +++ b/man/man4/zfs.4 @@ -15,7 +15,7 @@ .\" own identifying information: .\" Portions Copyright [yyyy] [name of copyright owner] .\" -.Dd June 1, 2021 +.Dd January 10, 2023 .Dt ZFS 4 .Os . @@ -233,6 +233,12 @@ relative to the pool. Make some blocks above a certain size be gang blocks. This option is used by the test suite to facilitate testing. . +.It Sy zfs_default_bs Ns = Ns Sy 9 Po 512 B Pc Pq int +Default dnode block size as a power of 2. +. +.It Sy zfs_default_ibs Ns = Ns Sy 17 Po 128 KiB Pc Pq int +Default dnode indirect block size as a power of 2. +. .It Sy zfs_history_output_max Ns = Ns Sy 1048576 Ns B Ns B Po 1MB Pc Pq int When attempting to log an output nvlist of an ioctl in the on-disk history, the output will not be stored if it is larger than this size (in bytes). diff --git a/module/os/freebsd/zfs/sysctl_os.c b/module/os/freebsd/zfs/sysctl_os.c index 5315b60982..b5db3f83eb 100644 --- a/module/os/freebsd/zfs/sysctl_os.c +++ b/module/os/freebsd/zfs/sysctl_os.c @@ -356,14 +356,6 @@ SYSCTL_UINT(_vfs_zfs_zfetch, OID_AUTO, max_idistance, CTLFLAG_RWTUN, /* dsl_pool.c */ /* dnode.c */ -extern int zfs_default_bs; -SYSCTL_INT(_vfs_zfs, OID_AUTO, default_bs, CTLFLAG_RWTUN, - &zfs_default_bs, 0, "Default dnode block shift"); - -extern int zfs_default_ibs; -SYSCTL_INT(_vfs_zfs, OID_AUTO, default_ibs, CTLFLAG_RWTUN, - &zfs_default_ibs, 0, "Default dnode indirect block shift"); - /* dsl_scan.c */ diff --git a/module/zfs/dnode.c b/module/zfs/dnode.c index 80e1d4dd63..ed75c3bdf6 100644 --- a/module/zfs/dnode.c +++ b/module/zfs/dnode.c @@ -2714,3 +2714,8 @@ EXPORT_SYMBOL(dnode_free_range); EXPORT_SYMBOL(dnode_evict_dbufs); EXPORT_SYMBOL(dnode_evict_bonus); #endif + +ZFS_MODULE_PARAM(zfs, zfs_, default_bs, INT, ZMOD_RW, + "Default dnode block shift"); +ZFS_MODULE_PARAM(zfs, zfs_, default_ibs, INT, ZMOD_RW, + "Default dnode indirect block shift");