diff options
author | kib <kib@FreeBSD.org> | 2012-10-22 17:50:54 +0000 |
---|---|---|
committer | kib <kib@FreeBSD.org> | 2012-10-22 17:50:54 +0000 |
commit | 560aa751e0f5cfef868bdf3fab01cdbc5169ef82 (patch) | |
tree | 6e9ef0a47c5e91d26227820c50c9767e84550821 /sys/geom/journal | |
parent | ca71b68ea40c83f641d6485e027368568f244197 (diff) | |
download | FreeBSD-src-560aa751e0f5cfef868bdf3fab01cdbc5169ef82.zip FreeBSD-src-560aa751e0f5cfef868bdf3fab01cdbc5169ef82.tar.gz |
Remove the support for using non-mpsafe filesystem modules.
In particular, do not lock Giant conditionally when calling into the
filesystem module, remove the VFS_LOCK_GIANT() and related
macros. Stop handling buffers belonging to non-mpsafe filesystems.
The VFS_VERSION is bumped to indicate the interface change which does
not result in the interface signatures changes.
Conducted and reviewed by: attilio
Tested by: pho
Diffstat (limited to 'sys/geom/journal')
-rw-r--r-- | sys/geom/journal/g_journal.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/sys/geom/journal/g_journal.c b/sys/geom/journal/g_journal.c index a31f590..4581430 100644 --- a/sys/geom/journal/g_journal.c +++ b/sys/geom/journal/g_journal.c @@ -2870,7 +2870,7 @@ g_journal_do_switch(struct g_class *classp) struct mount *mp; struct bintime bt; char *mountpoint; - int error, save, vfslocked; + int error, save; DROP_GIANT(); g_topology_lock(); @@ -2922,11 +2922,8 @@ g_journal_do_switch(struct g_class *classp) mountpoint = mp->mnt_stat.f_mntonname; - vfslocked = VFS_LOCK_GIANT(mp); - error = vn_start_write(NULL, &mp, V_WAIT); if (error != 0) { - VFS_UNLOCK_GIANT(vfslocked); GJ_DEBUG(0, "vn_start_write(%s) failed (error=%d).", mountpoint, error); goto next; @@ -2951,10 +2948,8 @@ g_journal_do_switch(struct g_class *classp) vn_finished_write(mp); - if (error != 0) { - VFS_UNLOCK_GIANT(vfslocked); + if (error != 0) goto next; - } /* * Send BIO_FLUSH before freezing the file system, so it can be @@ -2966,7 +2961,6 @@ g_journal_do_switch(struct g_class *classp) GJ_TIMER_START(1, &bt); error = vfs_write_suspend(mp); - VFS_UNLOCK_GIANT(vfslocked); GJ_TIMER_STOP(1, &bt, "Suspend time of %s", mountpoint); if (error != 0) { GJ_DEBUG(0, "Cannot suspend file system %s (error=%d).", |