diff options
Diffstat (limited to 'usr/src/uts/common/fs/vfs.c')
-rw-r--r-- | usr/src/uts/common/fs/vfs.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/usr/src/uts/common/fs/vfs.c b/usr/src/uts/common/fs/vfs.c index c9d154327e..3c2008f599 100644 --- a/usr/src/uts/common/fs/vfs.c +++ b/usr/src/uts/common/fs/vfs.c @@ -84,6 +84,7 @@ #include <sys/console.h> #include <sys/reboot.h> #include <sys/attr.h> +#include <sys/spa.h> #include <vm/page.h> @@ -353,6 +354,13 @@ fs_copyfsops(const fs_operation_def_t *template, vfsops_t *actual, return (fs_build_vector(actual, unused_ops, vfs_ops_table, template)); } +void +zfs_boot_init() { + + if (strcmp(rootfs.bo_fstype, MNTTYPE_ZFS) == 0) + spa_boot_init(); +} + int vfs_setfsops(int fstype, const fs_operation_def_t *template, vfsops_t **actual) { @@ -842,6 +850,12 @@ vfs_mountroot(void) * root filesystem instead of the boot program's services. */ modrootloaded = 1; + + /* + * Special handling for a ZFS root file system. + */ + zfs_boot_init(); + /* * Set up mnttab information for root */ |