Index: UPDATING =================================================================== --- UPDATING (revision 227308) +++ UPDATING (working copy) @@ -22,6 +22,12 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 10.x IS SLOW machines to maximize performance. (To disable malloc debugging, run ln -s aj /etc/malloc.conf.) +20111105: + The option VFS_ALLOW_NONMPSAFE option has been added in order to + explicitely support non-MPSAFE filesystems. + It is on by default for all supported platform at this present + time. + 20111101: The broken amd(4) driver has been replaced with esp(4) in the amd64, i386 and pc98 GENERIC kernel configuration files. Index: sys/arm/conf/DEFAULTS =================================================================== --- sys/arm/conf/DEFAULTS (revision 227308) +++ sys/arm/conf/DEFAULTS (working copy) @@ -9,3 +9,5 @@ device mem options GEOM_PART_BSD options GEOM_PART_MBR + +options VFS_ALLOW_NONMPSAFE Index: sys/powerpc/conf/DEFAULTS =================================================================== --- sys/powerpc/conf/DEFAULTS (revision 227308) +++ sys/powerpc/conf/DEFAULTS (working copy) @@ -12,3 +12,6 @@ device uart_z8530 options GEOM_PART_APM options GEOM_PART_MBR + +# Allow mounting non-MPSAFE filesystems +options VFS_ALLOW_NONMPSAFE Index: sys/sparc64/conf/DEFAULTS =================================================================== --- sys/sparc64/conf/DEFAULTS (revision 227308) +++ sys/sparc64/conf/DEFAULTS (working copy) @@ -21,3 +21,6 @@ options GEOM_PART_VTOC8 options SUNKBD_EMULATE_ATKBD options NEW_PCIB + +# Allow mounting non-MPSAFE filesystems +options VFS_ALLOW_NONMPSAFE Index: sys/conf/NOTES =================================================================== --- sys/conf/NOTES (revision 227308) +++ sys/conf/NOTES (working copy) @@ -1104,6 +1104,9 @@ options XFS # unsuitable for inclusion on machines with untrusted local users. options VFS_AIO +# Enable mounting of non-MPSAFE filesystems. +options VFS_ALLOW_NONMPSAFE + # Cryptographically secure random number generator; /dev/random device random Index: sys/conf/options =================================================================== --- sys/conf/options (revision 227308) +++ sys/conf/options (working copy) @@ -185,6 +185,7 @@ SYSVSHM opt_sysvipc.h SW_WATCHDOG opt_watchdog.h TURNSTILE_PROFILING VFS_AIO +VFS_ALLOW_NONMPSAFE VERBOSE_SYSINIT opt_global.h WLCACHE opt_wavelan.h WLDEBUG opt_wavelan.h Index: sys/kern/vfs_mount.c =================================================================== --- sys/kern/vfs_mount.c (revision 227308) +++ sys/kern/vfs_mount.c (working copy) @@ -37,6 +37,8 @@ #include __FBSDID("$FreeBSD$"); +#include "opt_vfs_allow_nonmpsafe.h" + #include #include #include @@ -798,6 +800,14 @@ vfs_domount_first( * get. No freeing of cn_pnbuf. */ error = VFS_MOUNT(mp); +#ifndef VFS_ALLOW_NONMPSAFE + if (error == 0 && VFS_NEEDSGIANT(mp)) { + (void)VFS_UNMOUNT(mp, fsflags); + error = ENXIO; + printf("%s: Mounting non-MPSAFE fs (%s) is disabled\n", + __func__, mp->mnt_vfc->vfc_name); + } +#endif if (error != 0) { vfs_unbusy(mp); vfs_mount_destroy(mp); @@ -807,6 +817,11 @@ vfs_domount_first( vrele(vp); return (error); } +#ifdef VFS_ALLOW_NONMPSAFE + if (VFS_NEEDSGIANT(mp)) + printf("%s: Mounting non-MPSAFE fs (%s) is deprecated\n", + __func__, mp->mnt_vfc->vfc_name); +#endif if (mp->mnt_opt != NULL) vfs_freeopts(mp->mnt_opt); Index: sys/ia64/conf/DEFAULTS =================================================================== --- sys/ia64/conf/DEFAULTS (revision 227308) +++ sys/ia64/conf/DEFAULTS (working copy) @@ -20,3 +20,6 @@ options GEOM_PART_GPT options GEOM_PART_MBR options NEW_PCIB + +# Allow mounting non-MPSAFE filesystems +options VFS_ALLOW_NONMPSAFE Index: sys/mips/conf/DEFAULTS =================================================================== --- sys/mips/conf/DEFAULTS (revision 227308) +++ sys/mips/conf/DEFAULTS (working copy) @@ -9,3 +9,5 @@ device uart_ns8250 options GEOM_PART_BSD options GEOM_PART_MBR + +options VFS_ALLOW_NONMPSAFE Index: sys/pc98/conf/DEFAULTS =================================================================== --- sys/pc98/conf/DEFAULTS (revision 227308) +++ sys/pc98/conf/DEFAULTS (working copy) @@ -29,3 +29,6 @@ options GEOM_PART_PC98 device atpic options NEW_PCIB + +# Allow mounting non-MPSAFE filesystems +options VFS_ALLOW_NONMPSAFE Index: sys/i386/conf/DEFAULTS =================================================================== --- sys/i386/conf/DEFAULTS (revision 227308) +++ sys/i386/conf/DEFAULTS (working copy) @@ -30,3 +30,6 @@ options NATIVE device atpic options NEW_PCIB + +# Allow mounting non-MPSAFE filesystems +options VFS_ALLOW_NONMPSAFE Index: sys/amd64/conf/DEFAULTS =================================================================== --- sys/amd64/conf/DEFAULTS (revision 227308) +++ sys/amd64/conf/DEFAULTS (working copy) @@ -22,3 +22,6 @@ options GEOM_PART_EBR_COMPAT options GEOM_PART_MBR options NEW_PCIB + +# Allow mounting non-MPSAFE filesystems +options VFS_ALLOW_NONMPSAFE