Date: Tue, 11 Sep 2012 04:54:44 +0000 (UTC) From: "Andrey V. Elsukov" <ae@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r240335 - in head/sys/boot: i386/loader sparc64/loader Message-ID: <201209110454.q8B4siJL079567@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: ae Date: Tue Sep 11 04:54:44 2012 New Revision: 240335 URL: http://svn.freebsd.org/changeset/base/240335 Log: Slightly reduce an overhead for the open() call in the zfsloader. libstand(3) tries to detect file system in the predefined order, but zfsloader usually is used for the booting from ZFS, and there is no need to try detect several file system types for each open() call. Modified: head/sys/boot/i386/loader/conf.c head/sys/boot/sparc64/loader/main.c Modified: head/sys/boot/i386/loader/conf.c ============================================================================== --- head/sys/boot/i386/loader/conf.c Tue Sep 11 04:53:32 2012 (r240334) +++ head/sys/boot/i386/loader/conf.c Tue Sep 11 04:54:44 2012 (r240335) @@ -70,6 +70,9 @@ struct devsw *devsw[] = { }; struct fs_ops *file_system[] = { +#if defined(LOADER_ZFS_SUPPORT) + &zfs_fsops, +#endif &ufs_fsops, &ext2fs_fsops, &dosfs_fsops, @@ -78,9 +81,6 @@ struct fs_ops *file_system[] = { &nandfs_fsops, #endif &splitfs_fsops, -#if defined(LOADER_ZFS_SUPPORT) - &zfs_fsops, -#endif #ifdef LOADER_GZIP_SUPPORT &gzipfs_fsops, #endif Modified: head/sys/boot/sparc64/loader/main.c ============================================================================== --- head/sys/boot/sparc64/loader/main.c Tue Sep 11 04:53:32 2012 (r240334) +++ head/sys/boot/sparc64/loader/main.c Tue Sep 11 04:54:44 2012 (r240335) @@ -170,15 +170,15 @@ struct file_format *file_formats[] = { }; struct fs_ops *file_system[] = { +#ifdef LOADER_ZFS_SUPPORT + &zfs_fsops, +#endif #ifdef LOADER_UFS_SUPPORT &ufs_fsops, #endif #ifdef LOADER_CD9660_SUPPORT &cd9660_fsops, #endif -#ifdef LOADER_ZFS_SUPPORT - &zfs_fsops, -#endif #ifdef LOADER_ZIP_SUPPORT &zipfs_fsops, #endif
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201209110454.q8B4siJL079567>