diff options
| author | Poul-Henning Kamp <phk@FreeBSD.org> | 2004-11-04 09:11:22 +0000 |
|---|---|---|
| committer | Poul-Henning Kamp <phk@FreeBSD.org> | 2004-11-04 09:11:22 +0000 |
| commit | 40c340aa5decbb3956e5716f8f57f82affd4c3bf (patch) | |
| tree | 1270ac9c9190e7ab3c48743613f17dfebf63b30f | |
| parent | 9f7a3028d558e940f66b1a735d0d739321fbbf73 (diff) | |
Notes
| -rw-r--r-- | sys/ufs/ffs/ffs_vfsops.c | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/sys/ufs/ffs/ffs_vfsops.c b/sys/ufs/ffs/ffs_vfsops.c index 6c100520625c..3a27b5a8a9dd 100644 --- a/sys/ufs/ffs/ffs_vfsops.c +++ b/sys/ufs/ffs/ffs_vfsops.c @@ -266,20 +266,6 @@ ffs_omount(struct mount *mp, char *path, caddr_t data, struct thread *td) } VOP_UNLOCK(devvp, 0, td); } - DROP_GIANT(); - g_topology_lock(); - /* - * If we're the root device, we may not have an E count - * yet, get it now. - */ - if (ump->um_cp->ace == 0) - error = g_access(ump->um_cp, 0, 1, 1); - else - error = g_access(ump->um_cp, 0, 1, 0); - g_topology_unlock(); - PICKUP_GIANT(); - if (error) - return (error); fs->fs_flags &= ~FS_UNCLEAN; if (fs->fs_clean == 0) { fs->fs_flags |= FS_UNCLEAN; @@ -295,6 +281,20 @@ ffs_omount(struct mount *mp, char *path, caddr_t data, struct thread *td) return (EPERM); } } + DROP_GIANT(); + g_topology_lock(); + /* + * If we're the root device, we may not have an E count + * yet, get it now. + */ + if (ump->um_cp->ace == 0) + error = g_access(ump->um_cp, 0, 1, 1); + else + error = g_access(ump->um_cp, 0, 1, 0); + g_topology_unlock(); + PICKUP_GIANT(); + if (error) + return (error); if ((error = vn_start_write(NULL, &mp, V_WAIT)) != 0) return (error); fs->fs_ronly = 0; |
