* Mark the swap dummy mount as being MPSAFE so strategy operations do not
acquire the mplock.
* Mark NULLFS mounts as being MPSAFE so operations do not acquire the
mplock. If the underlying VFS is not MPSAFE it will still acquire
the mplock.
TAILQ_INIT(&mntvnodescan_list);
mount_init(&dummymount);
dummymount.mnt_flag |= MNT_RDONLY;
+ dummymount.mnt_kern_flag |= MNTK_ALL_MPSAFE;
}
/*
ap.a_bio = bio;
if (vp->v_mount) {
-
VFS_MPLOCK_FLAG(vp->v_mount, MNTK_SG_MPSAFE);
DO_OPS(ops, error, &ap, vop_strategy);
VFS_MPUNLOCK(vp->v_mount);
mp->mnt_stat.f_mntfromname, mp->mnt_stat.f_mntfromname);
/*
- * So unmount won't complain about namecache refs still existing
+ * Set NCALIASED so unmount won't complain about namecache refs
+ * still existing.
+ *
+ * All NULLFS operations are MPSAFE, though it will be short-lived
+ * if the underlying filesystem is not.
*/
- mp->mnt_kern_flag |= MNTK_NCALIASED;
+ mp->mnt_kern_flag |= MNTK_NCALIASED | MNTK_ALL_MPSAFE;
return (0);
fail2:
nlookup_done(&nd);